<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/extcon/extcon.c, branch v4.14.286</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v4.14.286</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v4.14.286'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2022-06-14T14:54:00+00:00</updated>
<entry>
<title>extcon: Modify extcon device to be created after driver data is set</title>
<updated>2022-06-14T14:54:00+00:00</updated>
<author>
<name>bumwoo lee</name>
<email>bw365.lee@samsung.com</email>
</author>
<published>2022-04-27T03:00:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6e721f3ad0535b24f19a62420f4da95212cf069c'/>
<id>urn:sha1:6e721f3ad0535b24f19a62420f4da95212cf069c</id>
<content type='text'>
[ Upstream commit 5dcc2afe716d69f5112ce035cb14f007461ff189 ]

Currently, someone can invoke the sysfs such as state_show()
intermittently before dev_set_drvdata() is done.
And it can be a cause of kernel Oops because of edev is Null at that time.
So modified the driver registration to after setting drviver data.

- Oops's backtrace.

Backtrace:
[&lt;c067865c&gt;] (state_show) from [&lt;c05222e8&gt;] (dev_attr_show)
[&lt;c05222c0&gt;] (dev_attr_show) from [&lt;c02c66e0&gt;] (sysfs_kf_seq_show)
[&lt;c02c6648&gt;] (sysfs_kf_seq_show) from [&lt;c02c496c&gt;] (kernfs_seq_show)
[&lt;c02c4938&gt;] (kernfs_seq_show) from [&lt;c025e2a0&gt;] (seq_read)
[&lt;c025e11c&gt;] (seq_read) from [&lt;c02c50a0&gt;] (kernfs_fop_read)
[&lt;c02c5064&gt;] (kernfs_fop_read) from [&lt;c0231cac&gt;] (__vfs_read)
[&lt;c0231c5c&gt;] (__vfs_read) from [&lt;c0231ee0&gt;] (vfs_read)
[&lt;c0231e34&gt;] (vfs_read) from [&lt;c0232464&gt;] (ksys_read)
[&lt;c02323f0&gt;] (ksys_read) from [&lt;c02324fc&gt;] (sys_read)
[&lt;c02324e4&gt;] (sys_read) from [&lt;c00091d0&gt;] (__sys_trace_return)

Signed-off-by: bumwoo lee &lt;bw365.lee@samsung.com&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>extcon: Fix error handling in extcon_dev_register</title>
<updated>2021-04-07T10:47:03+00:00</updated>
<author>
<name>Dinghao Liu</name>
<email>dinghao.liu@zju.edu.cn</email>
</author>
<published>2021-01-19T08:10:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2d956c59648288da954b0cc0e008bd21d5f43823'/>
<id>urn:sha1:2d956c59648288da954b0cc0e008bd21d5f43823</id>
<content type='text'>
[ Upstream commit d3bdd1c3140724967ca4136755538fa7c05c2b4e ]

When devm_kcalloc() fails, we should execute device_unregister()
to unregister edev-&gt;dev from system.

Fixes: 046050f6e623e ("extcon: Update the prototype of extcon_register_notifier() with enum extcon")
Signed-off-by: Dinghao Liu &lt;dinghao.liu@zju.edu.cn&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>extcon: Release locking when sending the notification of connector state</title>
<updated>2018-09-09T17:55:56+00:00</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2018-06-14T02:16:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c0a8e047734ce3dcce51715108ff666829fa539e'/>
<id>urn:sha1:c0a8e047734ce3dcce51715108ff666829fa539e</id>
<content type='text'>
commit 8a9dbb779fe882325b9a0238494a7afaff2eb444 upstream.

Previously, extcon used the spinlock before calling the notifier_call_chain
to prevent the scheduled out of task and to prevent the notification delay.
When spinlock is locked for sending the notification, deadlock issue
occured on the side of extcon consumer device. To fix this issue,
extcon consumer device should always use the work. it is always not
reasonable to use work.

To fix this issue on extcon consumer device, release locking when sending
the notification of connector state.

Fixes: ab11af049f88 ("extcon: Add the synchronization extcon APIs to support the notification")
Cc: stable@vger.kernel.org
Cc: Roger Quadros &lt;rogerq@ti.com&gt;
Cc: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>extcon: Correct description to improve the readability</title>
<updated>2017-08-16T00:27:55+00:00</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2017-04-03T10:45:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6ab6094f370df082fdf2e117381dd323ce948f68'/>
<id>urn:sha1:6ab6094f370df082fdf2e117381dd323ce948f68</id>
<content type='text'>
The extcon files explains the detailed operation for functions and
what is meaning of extcon structure. There are different explanation
even if the same argument.

So, it modifies the description for both functions and structures
in order to improve the readability and guide the role of functions
more well.

Also, this patch fixes the mismatching license info as a GPL v2
and removes the inactive author information.

Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>extcon: Remove unused CABLE_NAME_MAX definition</title>
<updated>2017-08-16T00:27:55+00:00</updated>
<author>
<name>Chanwoo Choi</name>
<email>cwchoi00@gmail.com</email>
</author>
<published>2017-07-12T14:44:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=dd4ed69a0e6f5f6acb8dc19b87a5835b98a85062'/>
<id>urn:sha1:dd4ed69a0e6f5f6acb8dc19b87a5835b98a85062</id>
<content type='text'>
This patch removes the unused CABLE_NAME_MAX definition.

Signed-off-by: Chanwoo Choi &lt;cwchoi00@gmail.com&gt;
</content>
</entry>
<entry>
<title>extcon: Convert to using %pOF instead of full_name</title>
<updated>2017-07-19T01:37:10+00:00</updated>
<author>
<name>Rob Herring</name>
<email>robh@kernel.org</email>
</author>
<published>2017-07-18T21:43:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=5c27036d2b05d6bc763809871b58a48e9fa554fa'/>
<id>urn:sha1:5c27036d2b05d6bc763809871b58a48e9fa554fa</id>
<content type='text'>
Now that we have a custom printf format specifier, convert users of
full_name to use %pOF instead. This is preparation to remove storing
of the full path string for each node.

Signed-off-by: Rob Herring &lt;robh@kernel.org&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>extcon: Fix a typo in three comment lines</title>
<updated>2017-05-23T09:32:02+00:00</updated>
<author>
<name>Markus Elfring</name>
<email>elfring@users.sourceforge.net</email>
</author>
<published>2017-04-23T20:15:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=826a47e978303989a12d318b3539feefb127bbe6'/>
<id>urn:sha1:826a47e978303989a12d318b3539feefb127bbe6</id>
<content type='text'>
Adjust three words in this description for a function.

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>extcon: Use devm_kcalloc() in extcon_dev_register()</title>
<updated>2017-05-23T09:32:02+00:00</updated>
<author>
<name>Markus Elfring</name>
<email>elfring@users.sourceforge.net</email>
</author>
<published>2017-04-23T18:54:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3f5071a8b07b697993a16bbe9cbc8c876ba60048'/>
<id>urn:sha1:3f5071a8b07b697993a16bbe9cbc8c876ba60048</id>
<content type='text'>
A multiplication for the size determination of a memory allocation
indicated that an array data structure should be processed.
Thus use the corresponding function "devm_kcalloc".

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>extcon: Use BIT() macro for the left-shift operation</title>
<updated>2017-04-06T02:12:45+00:00</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2017-03-29T10:18:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=70641a0a84e1ae3c6eee3d47ed5a482f85b11e3e'/>
<id>urn:sha1:70641a0a84e1ae3c6eee3d47ed5a482f85b11e3e</id>
<content type='text'>
This patch just uses the BIT() macro to make the code simple.

Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>extcon: Remove porting compatibility of swich class</title>
<updated>2017-04-06T01:55:24+00:00</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2017-01-01T12:14:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c9d0f1d121cf038afc787ceb03d60798a1db389b'/>
<id>urn:sha1:c9d0f1d121cf038afc787ceb03d60798a1db389b</id>
<content type='text'>
This patch removes the porting compatibility for switch class
because there is no any usage and requirement of swich class
over a couple of years.

Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
</feed>
