From 6ef8f7da92750c3c25755fac39b561fff2d47378 Mon Sep 17 00:00:00 2001 From: Jakub Kicinski Date: Thu, 5 Jan 2023 22:33:59 -0800 Subject: devlink: don't require setting features before registration Requiring devlink_set_features() to be run before devlink is registered is overzealous. devlink_set_features() itself is a leftover from old workarounds which were trying to prevent initiating reload before probe was complete. Signed-off-by: Jakub Kicinski Reviewed-by: Jiri Pirko Signed-off-by: David S. Miller --- net/devlink/core.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'net/devlink/core.c') diff --git a/net/devlink/core.c b/net/devlink/core.c index 7cf0b3efbb2f..a31a317626d7 100644 --- a/net/devlink/core.c +++ b/net/devlink/core.c @@ -125,8 +125,6 @@ next: */ void devlink_set_features(struct devlink *devlink, u64 features) { - ASSERT_DEVLINK_NOT_REGISTERED(devlink); - WARN_ON(features & DEVLINK_F_RELOAD && !devlink_reload_supported(devlink->ops)); devlink->features = features; -- cgit v1.2.3