diff options
author | Bill Pemberton <wfp5p@virginia.edu> | 2009-04-23 15:54:56 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-06-19 11:00:33 -0700 |
commit | 8629efa4cbf6f89a54a85af4b8bc31762af01800 (patch) | |
tree | 38bc0ece93a8741f7715c8e271e23c19a366c678 /drivers/staging/comedi/drivers/amplc_pci230.c | |
parent | Staging: comedi: more fix the way structs are initialized. (diff) | |
download | linux-dev-8629efa4cbf6f89a54a85af4b8bc31762af01800.tar.xz linux-dev-8629efa4cbf6f89a54a85af4b8bc31762af01800.zip |
Staging: comedi: make use of ARRAY_SIZE macro
Replace instances of computing number of elements in an array with
sizeof(foo)/sizeof(struct footype) with the ARRAY_SIZE macro.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/comedi/drivers/amplc_pci230.c')
-rw-r--r-- | drivers/staging/comedi/drivers/amplc_pci230.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/comedi/drivers/amplc_pci230.c b/drivers/staging/comedi/drivers/amplc_pci230.c index 1d675173cd32..057443551c23 100644 --- a/drivers/staging/comedi/drivers/amplc_pci230.c +++ b/drivers/staging/comedi/drivers/amplc_pci230.c @@ -612,7 +612,7 @@ static struct comedi_driver driver_amplc_pci230 = { .detach = pci230_detach, .board_name = &pci230_boards[0].name, .offset = sizeof(pci230_boards[0]), - .num_names = sizeof(pci230_boards) / sizeof(pci230_boards[0]), + .num_names = ARRAY_SIZE(pci230_boards), }; COMEDI_PCI_INITCLEANUP(driver_amplc_pci230, pci230_pci_table); |