U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] phy: Fix u-boot coruption when fixed-phy is used
Date: Thu, 27 Dec 2018 10:47:54 -0500	[thread overview]
Message-ID: <20181227154754.GL16433@bill-the-cat> (raw)
In-Reply-To: <6a39ed60e60f94be2af9577f88214033fdabcd40.1545235056.git.michal.simek@xilinx.com>

On Wed, Dec 19, 2018 at 04:57:38PM +0100, Michal Simek wrote:

> When fixed-link phy is used subnode offset is used as phy address. This
> number is bigger then space allocated for bus structure (allocated via
> mdio_alloc).
> bus->phymap[] array has PHY_MAX_ADDR size (32).
> That's why writing bus->phymap[addr] where addr is < 0 or > PHY_MAX_ADDR
> is causing write to memory which can caused full U-Boot crash.
> 
> The patch is checking if address is in correct range.
> 
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20181227/36b3ea7d/attachment.sig>

      parent reply	other threads:[~2018-12-27 15:47 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-19 15:57 [U-Boot] [PATCH] phy: Fix u-boot coruption when fixed-phy is used Michal Simek
2018-12-20 13:13 ` Stefan Roese
2018-12-21  7:40   ` Michal Simek
2018-12-27 15:47 ` Tom Rini [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181227154754.GL16433@bill-the-cat \
    --to=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox