Commit ec94233c authored by Javier Carrasco's avatar Javier Carrasco Committed by Greg Kroah-Hartman

usb: misc: onboard_hub: use pointer consistently in the probe function

Commit 14485de4 ("usb: Use device_get_match_data()") overlooked the
already existing pointer to pdev->dev 'dev'.

Use the existing pointer 'dev' in device_get_match_data() to keep code
consistency.
Acked-by: default avatarMatthias Kaehlcke <mka@chromium.org>
Signed-off-by: default avatarJavier Carrasco <javier.carrasco@wolfvision.net>
Link: https://lore.kernel.org/r/20240305-onboard_xvf3500-v7-1-ad3fb50e593b@wolfvision.netSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 87850f6c
...@@ -260,7 +260,7 @@ static int onboard_hub_probe(struct platform_device *pdev) ...@@ -260,7 +260,7 @@ static int onboard_hub_probe(struct platform_device *pdev)
if (!hub) if (!hub)
return -ENOMEM; return -ENOMEM;
hub->pdata = device_get_match_data(&pdev->dev); hub->pdata = device_get_match_data(dev);
if (!hub->pdata) if (!hub->pdata)
return -EINVAL; return -EINVAL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment