* [U-Boot] [PATCH] net: zynq_gem: Initialize phyreg variable
@ 2018-06-13 8:33 Michal Simek
2018-06-13 18:45 ` Joe Hershberger
2018-06-13 19:02 ` [U-Boot] " Joe Hershberger
0 siblings, 2 replies; 3+ messages in thread
From: Michal Simek @ 2018-06-13 8:33 UTC (permalink / raw)
To: u-boot
In case of phyread()/phy_setup_op() timeout code is working with
uninitialized phyreg variable. Initialize this variable to make sure
that code it not working with random value.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---
drivers/net/zynq_gem.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/zynq_gem.c b/drivers/net/zynq_gem.c
index d1436807ffb9..14564e365e6e 100644
--- a/drivers/net/zynq_gem.c
+++ b/drivers/net/zynq_gem.c
@@ -244,7 +244,7 @@ static int phywrite(struct zynq_gem_priv *priv, u32 phy_addr,
static int phy_detection(struct udevice *dev)
{
int i;
- u16 phyreg;
+ u16 phyreg = 0;
struct zynq_gem_priv *priv = dev->priv;
if (priv->phyaddr != -1) {
--
1.9.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [U-Boot] [PATCH] net: zynq_gem: Initialize phyreg variable
2018-06-13 8:33 [U-Boot] [PATCH] net: zynq_gem: Initialize phyreg variable Michal Simek
@ 2018-06-13 18:45 ` Joe Hershberger
2018-06-13 19:02 ` [U-Boot] " Joe Hershberger
1 sibling, 0 replies; 3+ messages in thread
From: Joe Hershberger @ 2018-06-13 18:45 UTC (permalink / raw)
To: u-boot
On Wed, Jun 13, 2018 at 3:33 AM, Michal Simek <michal.simek@xilinx.com> wrote:
> In case of phyread()/phy_setup_op() timeout code is working with
> uninitialized phyreg variable. Initialize this variable to make sure
> that code it not working with random value.
>
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot] net: zynq_gem: Initialize phyreg variable
2018-06-13 8:33 [U-Boot] [PATCH] net: zynq_gem: Initialize phyreg variable Michal Simek
2018-06-13 18:45 ` Joe Hershberger
@ 2018-06-13 19:02 ` Joe Hershberger
1 sibling, 0 replies; 3+ messages in thread
From: Joe Hershberger @ 2018-06-13 19:02 UTC (permalink / raw)
To: u-boot
Hi Michal,
https://patchwork.ozlabs.org/patch/928754/ was applied to http://git.denx.de/?p=u-boot/u-boot-net.git
Thanks!
-Joe
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-06-13 19:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-13 8:33 [U-Boot] [PATCH] net: zynq_gem: Initialize phyreg variable Michal Simek
2018-06-13 18:45 ` Joe Hershberger
2018-06-13 19:02 ` [U-Boot] " Joe Hershberger
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.