<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/of/base.c, branch v3.9</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.9</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.9'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2013-02-13T10:09:31Z</updated>
<entry>
<title>of: Create function for counting number of phandles in a property</title>
<updated>2013-02-13T10:09:31Z</updated>
<author>
<name>Grant Likely</name>
<email>grant.likely@secretlab.ca</email>
</author>
<published>2013-02-10T22:57:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bd69f73f2c81eed9a398708b8c4bb3409ba1b0f9'/>
<id>urn:sha1:bd69f73f2c81eed9a398708b8c4bb3409ba1b0f9</id>
<content type='text'>
This patch creates of_count_phandle_with_args(), a new function for
counting the number of phandle+argument tuples in a given property. This
is better than the existing method of parsing each phandle individually
until parsing fails which is a horribly slow way to do the count.

Tested on ARM using the selftest code.

v3: - Rebased on top of selftest code cleanup patch
v2: - fix bug where of_parse_phandle_with_args() could behave like _count_.
    - made of_gpio_named_count() into a static inline regardless of CONFIG_OF_GPIO

Tested-by: Andreas Larsson &lt;andreas@gaisler.com&gt;
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
Cc: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Rob Herring &lt;rob.herring@calxeda.com&gt;
</content>
</entry>
<entry>
<title>of/base: Clean up exit paths for of_parse_phandle_with_args()</title>
<updated>2013-02-13T10:05:58Z</updated>
<author>
<name>Grant Likely</name>
<email>grant.likely@secretlab.ca</email>
</author>
<published>2013-02-12T21:21:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=23ce04c0734e33b1042273b0ed11a8e4f7f988ca'/>
<id>urn:sha1:23ce04c0734e33b1042273b0ed11a8e4f7f988ca</id>
<content type='text'>
Some of the exit paths were not correctly releasing the node. Fix it by
creating an 'err' label for collecting the error paths and releasing the
node.

Cc: Rob Herring &lt;rob.herring@calxeda.com&gt;
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
</content>
</entry>
<entry>
<title>of: fix recursive locking in of_get_next_available_child()</title>
<updated>2013-02-13T10:05:24Z</updated>
<author>
<name>Stephen Warren</name>
<email>swarren@nvidia.com</email>
</author>
<published>2013-02-11T21:15:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c31a0c052205e3ec24efc3fe18ef70c3e913f2d4'/>
<id>urn:sha1:c31a0c052205e3ec24efc3fe18ef70c3e913f2d4</id>
<content type='text'>
of_get_next_available_child() acquires devtree_lock, then calls
of_device_is_available() which calls of_get_property() which calls
of_find_property() which tries to re-acquire devtree_lock, thus causing
deadlock.

To avoid this, create a new __of_device_is_available() which calls
__of_get_property() instead, which calls __of_find_property(), which
does not take the lock,. Update of_get_next_available_child() to call
the new __of_device_is_available() since it already owns the lock.

Signed-off-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-next' from git://sources.calxeda.com/kernel/linux.git</title>
<updated>2013-02-13T09:59:13Z</updated>
<author>
<name>Grant Likely</name>
<email>grant.likely@secretlab.ca</email>
</author>
<published>2013-02-13T09:59:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bfc4a58986ba3934bb256ef3567aeeab262aa959'/>
<id>urn:sha1:bfc4a58986ba3934bb256ef3567aeeab262aa959</id>
<content type='text'>
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
</content>
</entry>
<entry>
<title>OF: convert devtree lock from rw_lock to raw spinlock</title>
<updated>2013-02-08T23:02:40Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2013-02-06T20:30:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d6d3c4e656513dcea61ce900f0ecb9ca820ee7cd'/>
<id>urn:sha1:d6d3c4e656513dcea61ce900f0ecb9ca820ee7cd</id>
<content type='text'>
With the locking cleanup in place (from "OF: Fixup resursive
locking code paths"), we can now do the conversion from the
rw_lock to a raw spinlock as required for preempt-rt.

The previous cleanup and this conversion were originally
separate since they predated when mainline got raw spinlock (in
commit c2f21ce2e31286a "locking: Implement new raw_spinlock").

So, at that point in time, the cleanup was considered plausible
for mainline, but not this conversion.  In any case, we've kept
them separate as it makes for easier review and better bisection.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
[PG: taken from preempt-rt, update subject &amp; add a commit log]
Signed-off-by: Paul Gortmaker &lt;paul.gortmaker@windriver.com&gt;
Signed-off-by: Rob Herring &lt;rob.herring@calxeda.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'robherring/for-next' from git://sources.calxeda.com/kernel/linux.git</title>
<updated>2013-02-08T09:23:33Z</updated>
<author>
<name>Grant Likely</name>
<email>grant.likely@secretlab.ca</email>
</author>
<published>2013-02-08T09:23:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d2f4ec1026fecbef9b72cc899a626516ef3f265f'/>
<id>urn:sha1:d2f4ec1026fecbef9b72cc899a626516ef3f265f</id>
<content type='text'>
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
</content>
</entry>
<entry>
<title>of: Output devicetree alias names in uevent</title>
<updated>2013-02-06T11:06:35Z</updated>
<author>
<name>Stepan Moskovchenko</name>
<email>stepanm@codeaurora.org</email>
</author>
<published>2012-12-06T22:55:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ced4eec900850627409d7ff566b009471162b56b'/>
<id>urn:sha1:ced4eec900850627409d7ff566b009471162b56b</id>
<content type='text'>
In some situations, userspace may want to resolve a
device by function and logical number (ie, "serial0")
rather than by the base address or full device path. Being
able to resolve a device by alias frees userspace from the
burden of otherwise having to maintain a mapping between
device addresses and their logical assignments on each
platform when multiple instances of the same hardware block
are present in the system.

Although the uevent device attribute contains devicetree
compatible information and the full device path, the uevent
does not list the alises that may have been defined for the
device.

Signed-off-by: Stepan Moskovchenko &lt;stepanm@codeaurora.org&gt;
[grant.likely: Removed OF_ALIAS_N field; I don't think it's needed]
[grant.likely: Added #ifndef _LINUX_OF_PRIVATE_H wrapper]
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
</content>
</entry>
<entry>
<title>OF: Fixup resursive locking code paths</title>
<updated>2013-01-28T02:20:23Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2013-01-25T18:21:47Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=28d0e36bf96863df1195f8f7b9fd559142873389'/>
<id>urn:sha1:28d0e36bf96863df1195f8f7b9fd559142873389</id>
<content type='text'>
There is no real reason to use a rwlock for devtree_lock. It even
could be a mutex, but unfortunately it's locked from cpu hotplug
paths which can't schedule :(

So it needs to become a raw lock on rt as well.  The devtree_lock would
be the only user of a raw_rw_lock, so we are better off cleaning up the
recursive locking paths which allows us to convert devtree_lock to a
read_lock.

Here we do the standard thing of introducing __foo() as the "raw"
version of foo(), so that we can take better control of the locking.
The "raw" versions are not exported and are for internal use within
the file itself.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Paul Gortmaker &lt;paul.gortmaker@windriver.com&gt;
Signed-off-by: Rob Herring &lt;rob.herring@calxeda.com&gt;
</content>
</entry>
<entry>
<title>of: fix incorrect return value of of_find_matching_node_and_match()</title>
<updated>2013-01-20T22:26:42Z</updated>
<author>
<name>Thomas Abraham</name>
<email>thomas.abraham@linaro.org</email>
</author>
<published>2013-01-19T18:20:42Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=dc71bcf1b99c265fffdb1e8c60e7933612f3bca7'/>
<id>urn:sha1:dc71bcf1b99c265fffdb1e8c60e7933612f3bca7</id>
<content type='text'>
The of_find_matching_node_and_match() function incorrectly sets the matched
entry to 'matches' when the compatible value of a node matches one of the
possible values. This results in incorrectly selecting the the first entry in
the 'matches' list as the matched entry. Fix this by noting down the result of
the call to of_match_node() and setting that as the matched entry.

Signed-off-by: Thomas Abraham &lt;thomas.abraham@linaro.org&gt;
Signed-off-by: Rob Herring &lt;rob.herring@calxeda.com&gt;
</content>
</entry>
<entry>
<title>of: Fix export of of_find_matching_node_and_match()</title>
<updated>2012-12-19T10:58:53Z</updated>
<author>
<name>Grant Likely</name>
<email>grant.likely@secretlab.ca</email>
</author>
<published>2012-12-19T10:45:36Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=80c2022e5645a1a789531d13010292c5c18bf1db'/>
<id>urn:sha1:80c2022e5645a1a789531d13010292c5c18bf1db</id>
<content type='text'>
Commit 50c8af4cf9, "of: introduce for_each_matching_node_and_match()"
renamed of_find_matching_node() to of_find_matching_node_and_match() and
created a new static inline of_find_matching_node() wrapper around the
new name. However, the change neglected to change the EXPORT_SYMBOL()
reference causing build errors for modules.

This patch fixes the EXPORT_SYMBOL() statement. Discovered on a PowerPC
Efika build with the mpc52xx_uart driver being built as a module.

Reported-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Grant Likely &lt;grant.likely@secretlab.ca&gt;
</content>
</entry>
</feed>
