usb: gadget: configfs: use to_config_usb_cfg() in os_desc_link()
authorLinyu Yuan <quic_linyyuan@quicinc.com>
Thu, 18 Nov 2021 04:53:32 +0000 (12:53 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:39:40 +0000 (09:39 +0100)
commitc955f9cf75b78945e1c9f8545b81d85f594003ec
treef4fc0ac61f4a6b94e5dfdc39b16c176d710ee964
parentf12829e5130fa7374e75f6494f70799c21718687
usb: gadget: configfs: use to_config_usb_cfg() in os_desc_link()

[ Upstream commit 5d143ec451429891385a21617b292f2ceaa684ea ]

replace open-coded container_of() with to_config_usb_cfg() helper.

Reviewed-by: Jack Pham <quic_jackp@quicinc.com>
Signed-off-by: Linyu Yuan <quic_linyyuan@quicinc.com>
Link: https://lore.kernel.org/r/1637211213-16400-4-git-send-email-quic_linyyuan@quicinc.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Stable-dep-of: 89e7252d6c7e ("usb: gadget: configfs: Restrict symlink creation is UDC already binded")
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/usb/gadget/configfs.c