From 0b8da8110b4fa3314a060e5c5a3b35a22b81e900 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Mon, 7 Dec 2020 14:12:30 +0100 Subject: s390/qeth: use dev->groups for common sysfs attributes All qeth devices have a minimum set of sysfs attributes, and non-OSN devices share a group of additional attributes. Depending on whether the device is forced to use a specific discipline, the device_type then specifies further attributes. Shift the common attributes into dev->groups, so that the device_type only contains the discipline-specific attributes. This avoids exposing the common attributes to the disciplines, and nicely cleans up our sysfs code. While replacing the qeth_l*_*_device_attributes() helpers, switch from sysfs_*_groups() to the more generic device_*_groups(). Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'drivers/s390/net/qeth_core.h') diff --git a/drivers/s390/net/qeth_core.h b/drivers/s390/net/qeth_core.h index 69b474f8735e..d150da95d073 100644 --- a/drivers/s390/net/qeth_core.h +++ b/drivers/s390/net/qeth_core.h @@ -1063,10 +1063,8 @@ extern const struct qeth_discipline qeth_l2_discipline; extern const struct qeth_discipline qeth_l3_discipline; extern const struct ethtool_ops qeth_ethtool_ops; extern const struct ethtool_ops qeth_osn_ethtool_ops; -extern const struct attribute_group *qeth_generic_attr_groups[]; -extern const struct attribute_group *qeth_osn_attr_groups[]; -extern const struct attribute_group qeth_device_attr_group; -extern const struct attribute_group qeth_device_blkt_group; +extern const struct attribute_group *qeth_dev_groups[]; +extern const struct attribute_group *qeth_osn_dev_groups[]; extern const struct device_type qeth_generic_devtype; const char *qeth_get_cardname_short(struct qeth_card *); -- cgit