Commit 4747cb01b158f91760577abdcd8372b11bbacfe7
Committed by
Afzal Mohammed
1 parent
23a1e7d118
Exists in
master
AM335X: cpsw lockdep warnings removal
This patch is added to remove lockdep warnings. sysfs_attr_init() is called for dynamically allocated sysfs attributes and so lockdep complaints are removed. Signed-off-by: Chandan Nath <chandan.nath@ti.com>
Showing 1 changed file with 3 additions and 0 deletions Side-by-side Diff
drivers/net/cpsw_ale.c
... | ... | @@ -18,6 +18,7 @@ |
18 | 18 | #include <linux/slab.h> |
19 | 19 | #include <linux/err.h> |
20 | 20 | #include <linux/io.h> |
21 | +#include <linux/sysfs.h> | |
21 | 22 | |
22 | 23 | #include "cpsw_ale.h" |
23 | 24 | |
24 | 25 | |
... | ... | @@ -631,10 +632,12 @@ |
631 | 632 | cpsw_ale_control_set(ale, 0, ALE_CLEAR, 1); |
632 | 633 | |
633 | 634 | ale->ale_control_attr = dev_attr_ale_control; |
635 | + sysfs_attr_init(&ale->ale_control_attr.attr); | |
634 | 636 | ret = device_create_file(ale->params.dev, &ale->ale_control_attr); |
635 | 637 | WARN_ON(ret < 0); |
636 | 638 | |
637 | 639 | ale->ale_table_attr = dev_attr_ale_table; |
640 | + sysfs_attr_init(&ale->ale_table_attr.attr); | |
638 | 641 | ret = device_create_file(ale->params.dev, &ale->ale_table_attr); |
639 | 642 | WARN_ON(ret < 0); |
640 | 643 |