<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/drivers/phy/phy-uclass.c, branch v2020.07</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>phy: Fix possible NULL pointer deference</title>
<updated>2020-05-25T15:54:53+00:00</updated>
<author>
<name>Vignesh Raghavendra</name>
<email>vigneshr@ti.com</email>
</author>
<published>2020-05-20T17:05:41+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=64b69f8c89352975c25730bcca4bf8af2296297f'/>
<id>64b69f8c89352975c25730bcca4bf8af2296297f</id>
<content type='text'>
It is possible that users of generic_phy_*() APIs may pass a valid
struct phy pointer but phy-&gt;dev can be NULL, leading to NULL pointer
deference in phy_dev_ops().

So call generic_phy_valid() to verify that phy and phy-&gt;dev are both
valid.

Signed-off-by: Vignesh Raghavendra &lt;vigneshr@ti.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is possible that users of generic_phy_*() APIs may pass a valid
struct phy pointer but phy-&gt;dev can be NULL, leading to NULL pointer
deference in phy_dev_ops().

So call generic_phy_valid() to verify that phy and phy-&gt;dev are both
valid.

Signed-off-by: Vignesh Raghavendra &lt;vigneshr@ti.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>common: Drop log.h from common header</title>
<updated>2020-05-19T01:19:18+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-05-10T17:40:05+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=f7ae49fc4f363a803dab3be078e93ead8e75a8e9'/>
<id>f7ae49fc4f363a803dab3be078e93ead8e75a8e9</id>
<content type='text'>
Move this header out of the common header.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Move this header out of the common header.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>phy: Use _nodev naming convention if non-device clients</title>
<updated>2020-05-10T20:00:49+00:00</updated>
<author>
<name>Jagan Teki</name>
<email>jagan@amarulasolutions.com</email>
</author>
<published>2020-05-01T18:14:18+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5a2b6778fac98f2cb9ee1e7e6b98cd88d18dcbb9'/>
<id>5a2b6778fac98f2cb9ee1e7e6b98cd88d18dcbb9</id>
<content type='text'>
Clients that are requesting some of uclass API's
without a device (with ofnode) usually have _nodev
naming convention.

- clk_get_by_index_nodev
- clk_get_by_name_nodev
- reset_get_by_index_nodev
- gpio_request_by_name_nodev

So, update the same naming convention PHY framework.

This doesn't change the existing functionality.

Cc: Neil Armstrong &lt;narmstrong@baylibre.com&gt;
Cc: Tom Rini &lt;trini@konsulko.com&gt;
Signed-off-by: Jagan Teki &lt;jagan@amarulasolutions.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Clients that are requesting some of uclass API's
without a device (with ofnode) usually have _nodev
naming convention.

- clk_get_by_index_nodev
- clk_get_by_name_nodev
- reset_get_by_index_nodev
- gpio_request_by_name_nodev

So, update the same naming convention PHY framework.

This doesn't change the existing functionality.

Cc: Neil Armstrong &lt;narmstrong@baylibre.com&gt;
Cc: Tom Rini &lt;trini@konsulko.com&gt;
Signed-off-by: Jagan Teki &lt;jagan@amarulasolutions.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>phy: Add API for a bulk of phys</title>
<updated>2020-05-02T10:32:28+00:00</updated>
<author>
<name>Chunfeng Yun</name>
<email>chunfeng.yun@mediatek.com</email>
</author>
<published>2020-05-02T09:35:11+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=b13307b470f4fdfad42aa4c1adcaf1960837d0c4'/>
<id>b13307b470f4fdfad42aa4c1adcaf1960837d0c4</id>
<content type='text'>
This patch adds a "bulk" API to the phy API in order to
get/init/exit/power on/off a group of phys associated
with a device.

The bulk API will avoid adding a copy of the same code to
manage a group of phys in drivers.

Signed-off-by: Chunfeng Yun &lt;chunfeng.yun@mediatek.com&gt;
Signed-off-by: Frank Wunderlich &lt;frank-w@public-files.de&gt;
Reviewed-by: Weijie Gao &lt;weijie.gao@mediatek.com&gt;
Reviewed-by: Jagan Teki &lt;jagan@amarulasolutions.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds a "bulk" API to the phy API in order to
get/init/exit/power on/off a group of phys associated
with a device.

The bulk API will avoid adding a copy of the same code to
manage a group of phys in drivers.

Signed-off-by: Chunfeng Yun &lt;chunfeng.yun@mediatek.com&gt;
Signed-off-by: Frank Wunderlich &lt;frank-w@public-files.de&gt;
Reviewed-by: Weijie Gao &lt;weijie.gao@mediatek.com&gt;
Reviewed-by: Jagan Teki &lt;jagan@amarulasolutions.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>generic-phy: add generic_phy_get_by_node()</title>
<updated>2020-04-20T12:19:10+00:00</updated>
<author>
<name>Neil Armstrong</name>
<email>narmstrong@baylibre.com</email>
</author>
<published>2020-03-30T09:27:23+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=c2b9aa98bf44e9537222c5c8d6ea365d5220f2e4'/>
<id>c2b9aa98bf44e9537222c5c8d6ea365d5220f2e4</id>
<content type='text'>
Add generic_phy_get_by_node() to get a PHY phandle from a node instead
of a udevice.

Signed-off-by: Neil Armstrong &lt;narmstrong@baylibre.com&gt;
Reviewed-by: Tom Rini &lt;trini@konsulko.com&gt;
[narmstrong: fixed by including ofnode.h in generic-phy.h]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add generic_phy_get_by_node() to get a PHY phandle from a node instead
of a udevice.

Signed-off-by: Neil Armstrong &lt;narmstrong@baylibre.com&gt;
Reviewed-by: Tom Rini &lt;trini@konsulko.com&gt;
[narmstrong: fixed by including ofnode.h in generic-phy.h]
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers: phy: Handle gracefully NULL pointers</title>
<updated>2019-10-31T11:22:53+00:00</updated>
<author>
<name>Jean-Jacques Hiblot</name>
<email>jjhiblot@ti.com</email>
</author>
<published>2019-10-01T12:03:26+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=4e1842988364446ba0cf2171d1eebb53c15bc44e'/>
<id>4e1842988364446ba0cf2171d1eebb53c15bc44e</id>
<content type='text'>
For some controllers PHYs can be optional. Handling NULL pointers without
crashing nor failing, makes it easy to handle optional PHYs.

Signed-off-by: Jean-Jacques Hiblot &lt;jjhiblot@ti.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For some controllers PHYs can be optional. Handling NULL pointers without
crashing nor failing, makes it easy to handle optional PHYs.

Signed-off-by: Jean-Jacques Hiblot &lt;jjhiblot@ti.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>phy: Fix off-by-one error when parsing DT PHY bindings</title>
<updated>2018-08-14T09:31:19+00:00</updated>
<author>
<name>Marek Vasut</name>
<email>marek.vasut+renesas@gmail.com</email>
</author>
<published>2018-08-07T10:24:35+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5e50adf6679831bc34a567a1bf20ff1642c418dd'/>
<id>5e50adf6679831bc34a567a1bf20ff1642c418dd</id>
<content type='text'>
The code fails to copy the last PHY phandle argument, so it is
missing from the adjusted phandle args and the consumer cannot
use it to determine what the PHY should do.

Signed-off-by: Marek Vasut &lt;marek.vasut+renesas@gmail.com&gt;
Cc: Patrice Chotard &lt;patrice.chotard@st.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The code fails to copy the last PHY phandle argument, so it is
missing from the adjusted phandle args and the consumer cannot
use it to determine what the PHY should do.

Signed-off-by: Marek Vasut &lt;marek.vasut+renesas@gmail.com&gt;
Cc: Patrice Chotard &lt;patrice.chotard@st.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>phy: Be able to get phy from PHY provider</title>
<updated>2018-07-19T20:31:35+00:00</updated>
<author>
<name>Patrice Chotard</name>
<email>patrice.chotard@st.com</email>
</author>
<published>2018-06-27T09:55:42+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=a1b2faed7cbaf23d4af8a629c4db1bebb8e99d1b'/>
<id>a1b2faed7cbaf23d4af8a629c4db1bebb8e99d1b</id>
<content type='text'>
In case of phy are provided from a PHY provider nodes as following:

usbphyc: usb-phy@5a006000 {
	compatible = "st,stm32mp1-usbphyc";
	reg = &lt;0x5a006000 0x1000&gt;;
	clocks = &lt;&amp;rcc_clk USBPHY_K&gt;;
	resets = &lt;&amp;rcc_rst USBPHY_R&gt;;
	#address-cells = &lt;1&gt;;
	#size-cells = &lt;0&gt;;

	usbphyc_port0: usb-phy@0 {
		reg = &lt;0&gt;;
		phy-supply = &lt;&amp;vdd_usb&gt;;
		vdda1v1-supply = &lt;&amp;reg11&gt;;
		vdda1v8-supply = &lt;&amp;reg18&gt;
		#phy-cells = &lt;0&gt;;
	};

	usbphyc_port1: usb-phy@1 {
		reg = &lt;1&gt;;
		phy-supply = &lt;&amp;vdd_usb&gt;;
		vdda1v1-supply = &lt;&amp;reg11&gt;;
		vdda1v8-supply = &lt;&amp;reg18&gt;
		#phy-cells = &lt;1&gt;;
	};
};

and PHY are called as following:

usbh_ehci: usbh-ehci@5800d000 {
	compatible = "generic-ehci";
	reg = &lt;0x5800d000 0x1000&gt;;
	clocks = &lt;&amp;rcc_clk USBH&gt;;
	resets = &lt;&amp;rcc_rst USBH_R&gt;;
	interrupts = &lt;GIC_SPI 75 IRQ_TYPE_NONE&gt;;
	companion = &lt;&amp;usbh_ohci&gt;;
	phys = &lt;&amp;usbphyc_port0&gt;;
	phy-names = "usb";
	status = "okay";
};

generic_phy_get_by_index() must be updated to first look for
PHY phandle as previously and in case of error looks for PHY
provider by finding the parent's current node which is the PHY
provider.
args (ofnode_phandle_args struct) must also be updated by inserting
the phy index into the PHY provider as args[0].

Signed-off-by: Patrice Chotard &lt;patrice.chotard@st.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In case of phy are provided from a PHY provider nodes as following:

usbphyc: usb-phy@5a006000 {
	compatible = "st,stm32mp1-usbphyc";
	reg = &lt;0x5a006000 0x1000&gt;;
	clocks = &lt;&amp;rcc_clk USBPHY_K&gt;;
	resets = &lt;&amp;rcc_rst USBPHY_R&gt;;
	#address-cells = &lt;1&gt;;
	#size-cells = &lt;0&gt;;

	usbphyc_port0: usb-phy@0 {
		reg = &lt;0&gt;;
		phy-supply = &lt;&amp;vdd_usb&gt;;
		vdda1v1-supply = &lt;&amp;reg11&gt;;
		vdda1v8-supply = &lt;&amp;reg18&gt;
		#phy-cells = &lt;0&gt;;
	};

	usbphyc_port1: usb-phy@1 {
		reg = &lt;1&gt;;
		phy-supply = &lt;&amp;vdd_usb&gt;;
		vdda1v1-supply = &lt;&amp;reg11&gt;;
		vdda1v8-supply = &lt;&amp;reg18&gt;
		#phy-cells = &lt;1&gt;;
	};
};

and PHY are called as following:

usbh_ehci: usbh-ehci@5800d000 {
	compatible = "generic-ehci";
	reg = &lt;0x5800d000 0x1000&gt;;
	clocks = &lt;&amp;rcc_clk USBH&gt;;
	resets = &lt;&amp;rcc_rst USBH_R&gt;;
	interrupts = &lt;GIC_SPI 75 IRQ_TYPE_NONE&gt;;
	companion = &lt;&amp;usbh_ohci&gt;;
	phys = &lt;&amp;usbphyc_port0&gt;;
	phy-names = "usb";
	status = "okay";
};

generic_phy_get_by_index() must be updated to first look for
PHY phandle as previously and in case of error looks for PHY
provider by finding the parent's current node which is the PHY
provider.
args (ofnode_phandle_args struct) must also be updated by inserting
the phy index into the PHY provider as args[0].

Signed-off-by: Patrice Chotard &lt;patrice.chotard@st.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>SPDX: Convert all of our single license tags to Linux Kernel style</title>
<updated>2018-05-07T13:34:12+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2018-05-06T21:58:06+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=83d290c56fab2d38cd1ab4c4cc7099559c1d5046'/>
<id>83d290c56fab2d38cd1ab4c4cc7099559c1d5046</id>
<content type='text'>
When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from.  So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry.  Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents.  There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from.  So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry.  Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.

In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.

This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents.  There's also a few places where I found we did not have a tag
and have introduced one.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove unnecessary instances of DECLARE_GLOBAL_DATA_PTR</title>
<updated>2018-04-27T18:54:48+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2018-04-18T17:50:47+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=d024236e5a31a2b4b82cbcc98b31b8170fc88d28'/>
<id>d024236e5a31a2b4b82cbcc98b31b8170fc88d28</id>
<content type='text'>
We have a large number of places where while we historically referenced
gd in the code we no longer do, as well as cases where the code added
that line "just in case" during development and never dropped it.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We have a large number of places where while we historically referenced
gd in the code we no longer do, as well as cases where the code added
that line "just in case" during development and never dropped it.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
