<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/usb/common/common.c, branch v6.19.11</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2024-12-23T17:40:26+00:00</updated>
<entry>
<title>usb: common: expand documentation for USB functions</title>
<updated>2024-12-23T17:40:26+00:00</updated>
<author>
<name>Lucy Mielke</name>
<email>lucymielke@icloud.com</email>
</author>
<published>2024-12-10T10:29:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=fe021328dfc29ef617a969a04d8727d5a57ae6f9'/>
<id>urn:sha1:fe021328dfc29ef617a969a04d8727d5a57ae6f9</id>
<content type='text'>
This patch adds documentation for two USB functions:
- usb_otg_state_string(), which returns a human-readable name for OTG
  states and
- usb_get_dr_mode_from_string(), which returns the dual role mode for a
  given string.

Signed-off-by: Lucy Mielke &lt;lucymielke@icloud.com&gt;
Link: https://lore.kernel.org/r/6nvegfmo6d5ak4soaf5nyifsaasfts4qlsnnpsd4sgpnikc2jd@amfmgdr5n3bi
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>USB: make single lock for all usb dynamic id lists</title>
<updated>2024-11-14T16:05:20+00:00</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2024-11-13T06:49:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=0b3144da31f855fce652303f588416a60991bdef'/>
<id>urn:sha1:0b3144da31f855fce652303f588416a60991bdef</id>
<content type='text'>
There are a number of places where we accidentally pass in a constant
structure to later cast it off to a dynamic one, and then attempt to
grab a lock on it, which is not a good idea.  To help resolve this, move
the dynamic id lock out of the dynamic id structure for the driver and
into one single lock for all USB dynamic ids.  As this lock should never
have any real contention (it's only every accessed when a device is
added or removed, which is always serialized) there should not be any
difference except for some memory savings.

Note, this just converts the existing use of the dynamic id lock to the
new static lock, there is one place that is accessing the dynamic id
list without grabbing the lock, that will be fixed up in a follow-on
change.

Cc: Johan Hovold &lt;johan@kernel.org&gt;
Cc: Herve Codina &lt;herve.codina@bootlin.com&gt;
Cc: Rob Herring &lt;robh@kernel.org&gt;
Cc: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Cc: Grant Grundler &lt;grundler@chromium.org&gt;
Cc: Oliver Neukum &lt;oneukum@suse.com&gt;
Cc: Yajun Deng &lt;yajun.deng@linux.dev&gt;
Cc: Douglas Anderson &lt;dianders@chromium.org&gt;
Cc: linux-usb@vger.kernel.org
Link: https://lore.kernel.org/r/2024111322-kindly-finalist-d247@gregkh
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: Switch to device_property_match_property_string()</title>
<updated>2024-09-11T13:34:34+00:00</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2024-09-03T18:31:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=64fa3bc36d3cf6b58f9981d9c5d353777de7952e'/>
<id>urn:sha1:64fa3bc36d3cf6b58f9981d9c5d353777de7952e</id>
<content type='text'>
Replace open coded device_property_match_property_string().

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Link: https://lore.kernel.org/r/20240903183136.3641770-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: Use helper function for_each_node_with_property()</title>
<updated>2024-08-13T08:37:21+00:00</updated>
<author>
<name>Zhang Zekun</name>
<email>zhangzekun11@huawei.com</email>
</author>
<published>2024-08-09T08:27:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=88177cd4537faf927fe994db99b62d75f73cb1fe'/>
<id>urn:sha1:88177cd4537faf927fe994db99b62d75f73cb1fe</id>
<content type='text'>
for_each_node_with_property() can iterate through the device_node
with a given property name, and we don't need to find the device_node
in the while loop. Since of_device_is_available() will return false if
the "controller" is NULL and break the while loop, there is no functional
change with such conversion.

Signed-off-by: Zhang Zekun &lt;zhangzekun11@huawei.com&gt;
Link: https://lore.kernel.org/r/20240809082711.99085-1-zhangzekun11@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: add missing MODULE_DESCRIPTION() macros</title>
<updated>2024-06-20T17:18:47+00:00</updated>
<author>
<name>Jeff Johnson</name>
<email>quic_jjohnson@quicinc.com</email>
</author>
<published>2024-06-12T01:54:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=5a94c9a3129ced550f8d73feb06f3feeb4edf61d'/>
<id>urn:sha1:5a94c9a3129ced550f8d73feb06f3feeb4edf61d</id>
<content type='text'>
With ARCH=x86, make allmodconfig &amp;&amp; make W=1 C=1 reports:
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/common/usb-common.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/usb/common/usb-otg-fsm.o

Add the missing invocations of the MODULE_DESCRIPTION() macro.

Signed-off-by: Jeff Johnson &lt;quic_jjohnson@quicinc.com&gt;
Link: https://lore.kernel.org/r/20240611-md-drivers-usb-common-v1-1-f81555b0bd0d@quicinc.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: Explicitly include correct DT includes</title>
<updated>2023-07-25T16:20:02+00:00</updated>
<author>
<name>Rob Herring</name>
<email>robh@kernel.org</email>
</author>
<published>2023-07-18T14:30:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=484468fb0f7dbac88f050009a5145ed1ee744a7e'/>
<id>urn:sha1:484468fb0f7dbac88f050009a5145ed1ee744a7e</id>
<content type='text'>
The DT of_device.h and of_platform.h date back to the separate
of_platform_bus_type before it as merged into the regular platform bus.
As part of that merge prepping Arm DT support 13 years ago, they
"temporarily" include each other. They also include platform_device.h
and of.h. As a result, there's a pretty much random mix of those include
files used throughout the tree. In order to detangle these headers and
replace the implicit includes with struct declarations, users need to
explicitly include the correct includes.

Acked-by: Herve Codina &lt;herve.codina@bootlin.com&gt;
Signed-off-by: Rob Herring &lt;robh@kernel.org&gt;
Link: https://lore.kernel.org/r/20230718143027.1064731-1-robh@kernel.org
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: add helper to get role-switch-default-mode</title>
<updated>2021-07-27T13:58:37+00:00</updated>
<author>
<name>Chunfeng Yun</name>
<email>chunfeng.yun@mediatek.com</email>
</author>
<published>2021-07-15T09:07:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2037f2991ddedded1ef4aaabe4caf11e306158dc'/>
<id>urn:sha1:2037f2991ddedded1ef4aaabe4caf11e306158dc</id>
<content type='text'>
Add helper to get "role-switch-default-mode", and convert it
to the corresponding enum usb_dr_mode

Signed-off-by: Chunfeng Yun &lt;chunfeng.yun@mediatek.com&gt;
Link: https://lore.kernel.org/r/1626340078-29111-6-git-send-email-chunfeng.yun@mediatek.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: move function's kerneldoc next to its definition</title>
<updated>2021-03-10T08:37:17+00:00</updated>
<author>
<name>Chunfeng Yun</name>
<email>chunfeng.yun@mediatek.com</email>
</author>
<published>2021-03-08T02:52:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=365038f24b3e9d2b7c9e499f03f432040e28a35c'/>
<id>urn:sha1:365038f24b3e9d2b7c9e499f03f432040e28a35c</id>
<content type='text'>
Following a general rule, add the kerneldoc for a function next
to it's definition, but not next to its declaration in a header
file.

Suggested-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Suggested-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Chunfeng Yun &lt;chunfeng.yun@mediatek.com&gt;
Link: https://lore.kernel.org/r/c4d2e010ae2bf67cdfa0b55e6d1deb9339d9d3dc.1615170625.git.chunfeng.yun@mediatek.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: add function to get interval expressed in us unit</title>
<updated>2021-03-10T08:37:17+00:00</updated>
<author>
<name>Chunfeng Yun</name>
<email>chunfeng.yun@mediatek.com</email>
</author>
<published>2021-03-08T02:52:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=fb95c7cf5600b7b74412f27dfb39a1e13fd8a90d'/>
<id>urn:sha1:fb95c7cf5600b7b74412f27dfb39a1e13fd8a90d</id>
<content type='text'>
Add a new function to convert bInterval into the time expressed
in 1us unit.

Signed-off-by: Chunfeng Yun &lt;chunfeng.yun@mediatek.com&gt;
Link: https://lore.kernel.org/r/25c8a09b055f716c1e5bf11fea72c3418f844482.1615170625.git.chunfeng.yun@mediatek.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: common: Parse for USB SSP genXxY</title>
<updated>2021-02-06T13:21:21+00:00</updated>
<author>
<name>Thinh Nguyen</name>
<email>Thinh.Nguyen@synopsys.com</email>
</author>
<published>2021-01-20T01:36:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=52c2d15703c3a900d5f78cd599b823db40d5100b'/>
<id>urn:sha1:52c2d15703c3a900d5f78cd599b823db40d5100b</id>
<content type='text'>
The USB "maximum-speed" property can now take the SSP signaling rate
generation and lane count with these new strings:

"super-speed-plus-gen2x2"
"super-speed-plus-gen2x1"
"super-speed-plus-gen1x2"

Introduce usb_get_maximum_ssp_rate() to parse for the corresponding
usb_ssp_rate enum. The original usb_get_maximum_speed() will return
USB_SPEED_SUPER_PLUS if it matches one of these new strings.

Signed-off-by: Thinh Nguyen &lt;Thinh.Nguyen@synopsys.com&gt;
Link: https://lore.kernel.org/r/f8ed896313d8cd8e2d2b540fc82db92b3ddf8a47.1611106162.git.Thinh.Nguyen@synopsys.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
