From 24c7bcb6a74914b529859a07fde27a1a55e13ade Mon Sep 17 00:00:00 2001 From: Alexander Shishkin Date: Fri, 5 Oct 2018 15:42:57 +0300 Subject: stm class: Switch over to the protocol driver Now that the default framing protocol is factored out into its own driver, switch over to using the driver for writing data. To that end, make the policy code require a valid protocol name (or absence thereof, which is equivalent to "p_basic"). Also, to make transition easier, make stm class request "p_basic" module at initialization time. Signed-off-by: Alexander Shishkin Tested-by: Mathieu Poirier Signed-off-by: Greg Kroah-Hartman --- drivers/hwtracing/stm/policy.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'drivers/hwtracing/stm/policy.c') diff --git a/drivers/hwtracing/stm/policy.c b/drivers/hwtracing/stm/policy.c index 8bc90432ae69..5e51bed0787b 100644 --- a/drivers/hwtracing/stm/policy.c +++ b/drivers/hwtracing/stm/policy.c @@ -454,8 +454,7 @@ stp_policy_make(struct config_group *group, const char *name) err = stm_lookup_protocol(proto, &pdrv, &pdrv_node_type); kfree(devname); - /* We don't have any protocol drivers yet */ - if (err != -ENOENT) { + if (err) { stm_put_device(stm); return ERR_PTR(-ENODEV); } -- cgit v1.2.3