aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Hemminger <stephen@networkplumber.org>2018-04-16 14:19:25 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-04-23 06:43:48 -0400
commit9ab877a6ccf820483d79602bede0c1aa1da4d26a (patch)
treee1cb6b77cbfb8794ab890fe9cc64f3a4ccd46a30
parent6e3d66b80f670fdc64b9a120362a9f94b0494621 (diff)
uio_hv_generic: make ring buffer attribute for primary channel
The primary channel also needs a ring buffer attribute. This allows application to check if kernel supports uio sub channels, and also makes all channels use consistent API. Fixes: 37b96a4931db ("uio_hv_generic: support sub-channels") Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/uio/uio_hv_generic.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/uio/uio_hv_generic.c b/drivers/uio/uio_hv_generic.c
index 7ff659dff11d..972a42dd2a46 100644
--- a/drivers/uio/uio_hv_generic.c
+++ b/drivers/uio/uio_hv_generic.c
@@ -326,6 +326,11 @@ hv_uio_probe(struct hv_device *dev,
326 vmbus_set_chn_rescind_callback(dev->channel, hv_uio_rescind); 326 vmbus_set_chn_rescind_callback(dev->channel, hv_uio_rescind);
327 vmbus_set_sc_create_callback(dev->channel, hv_uio_new_channel); 327 vmbus_set_sc_create_callback(dev->channel, hv_uio_new_channel);
328 328
329 ret = sysfs_create_bin_file(&dev->channel->kobj, &ring_buffer_bin_attr);
330 if (ret)
331 dev_notice(&dev->device,
332 "sysfs create ring bin file failed; %d\n", ret);
333
329 hv_set_drvdata(dev, pdata); 334 hv_set_drvdata(dev, pdata);
330 335
331 return 0; 336 return 0;