All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tim Harvey <tharvey@gateworks.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2] dwc_ahsata: return failure for MX6 if not IMX6Q/IMX6D
Date: Thu, 5 Jun 2014 03:46:43 -0700	[thread overview]
Message-ID: <CAJ+vNU1+ZqH6q4SiJWJKTT1amZOcZLNWiJt1gJFxDCrbAw5TMA@mail.gmail.com> (raw)
In-Reply-To: <1399526615-12204-1-git-send-email-tharvey@gateworks.com>

On Wed, May 7, 2014 at 10:23 PM, Tim Harvey <tharvey@gateworks.com> wrote:
> The IMX6QUAD/DUAL have SATA, but the IMX6SOLO/DL do not. Return failure
> instead of attempting a memory access that results in a data abort and reset.
>
> Signed-off-by: Tim Harvey <tharvey@gateworks.com>
> ---
> v2:
>  - remove print as this condition isn't really an error just something not
>    possible
> ---
>  drivers/block/dwc_ahsata.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/drivers/block/dwc_ahsata.c b/drivers/block/dwc_ahsata.c
> index 3569214..15d65d7 100644
> --- a/drivers/block/dwc_ahsata.c
> +++ b/drivers/block/dwc_ahsata.c
> @@ -17,6 +17,7 @@
>  #include <asm/io.h>
>  #include <linux/bitops.h>
>  #include <asm/arch/clock.h>
> +#include <asm/arch/sys_proto.h>
>  #include "dwc_ahsata.h"
>
>  struct sata_port_regs {
> @@ -558,6 +559,10 @@ int init_sata(int dev)
>         u32 linkmap;
>         struct ahci_probe_ent *probe_ent = NULL;
>
> +#if defined(CONFIG_MX6)
> +       if (!is_cpu_type(MXC_CPU_MX6Q) && !is_cpu_type(MXC_CPU_MX6D))
> +               return 1;
> +#endif
>         if (dev < 0 || dev > (CONFIG_SYS_SATA_MAX_DEVICE - 1)) {
>                 printf("The sata index %d is out of ranges\n\r", dev);
>                 return -1;
> --
> 1.8.3.2
>

Stefano,

Any comments or does anyone else need to review this?

Regards,

Tim

  reply	other threads:[~2014-06-05 10:46 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-06  5:22 [U-Boot] [PATCH] dwc_ahsata: return failure for MX6 if not IMX6Q Tim Harvey
2014-05-06  8:17 ` Stefano Babic
2014-05-06 19:55 ` Troy Kisky
2014-05-07  3:55   ` Tim Harvey
2014-05-08  5:23 ` [U-Boot] [PATCH v2] dwc_ahsata: return failure for MX6 if not IMX6Q/IMX6D Tim Harvey
2014-06-05 10:46   ` Tim Harvey [this message]
2014-06-06  8:18   ` Stefano Babic
2014-05-08  5:24 ` [U-Boot] [PATCH] imx: sata: return failure " Tim Harvey
2014-06-05 10:44   ` Tim Harvey
2014-06-05 10:53     ` Stefano Babic
2014-06-06  8:18     ` Stefano Babic

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=CAJ+vNU1+ZqH6q4SiJWJKTT1amZOcZLNWiJt1gJFxDCrbAw5TMA@mail.gmail.com \
    --to=tharvey@gateworks.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 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.