Skip to content

Commit

Permalink
misdn: one handmade ARRAY_SIZE converted
Browse files Browse the repository at this point in the history
Defined as:

static struct device_attribute element_attributes[] = {

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Karsten Keil <kkeil@suse.de>
  • Loading branch information
Ilpo Järvinen authored and Karsten Keil committed Jan 11, 2009
1 parent 20b7880 commit 1916ebb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/isdn/mISDN/dsp_pipeline.c
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,7 @@ int mISDN_dsp_element_register(struct mISDN_dsp_element *elem)
}
list_add_tail(&entry->list, &dsp_elements);

for (i = 0; i < (sizeof(element_attributes)
/ sizeof(struct device_attribute)); ++i)
for (i = 0; i < ARRAY_SIZE(element_attributes); ++i)
ret = device_create_file(&entry->dev,
&element_attributes[i]);
if (ret) {
Expand Down

0 comments on commit 1916ebb

Please sign in to comment.