Re: [PATCH 3/4] ARM: tegra30: Add Tegra Memory Controller(MC) driver |
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: Re: [PATCH 3/4] ARM: tegra30: Add Tegra Memory Controller(MC) driver
- From: Hiroshi Doyu <hdoyu@xxxxxxxxxx>
- Date: Fri, 11 May 2012 08:16:55 +0200
- Accept-language: en-US
- Acceptlanguage: en-US
- Cc: "linux-tegra@xxxxxxxxxxxxxxx" <linux-tegra@xxxxxxxxxxxxxxx>, "grant.likely@xxxxxxxxxxxx" <grant.likely@xxxxxxxxxxxx>, "rob.herring@xxxxxxxxxxx" <rob.herring@xxxxxxxxxxx>, "rob@xxxxxxxxxxx" <rob@xxxxxxxxxxx>, "ccross@xxxxxxxxxxx" <ccross@xxxxxxxxxxx>, "olof@xxxxxxxxx" <olof@xxxxxxxxx>, "swarren@xxxxxxxxxxxxx" <swarren@xxxxxxxxxxxxx>, "linux@xxxxxxxxxxxxxxxx" <linux@xxxxxxxxxxxxxxxx>, "santosh.shilimkar@xxxxxx" <santosh.shilimkar@xxxxxx>, "b-cousson@xxxxxx" <b-cousson@xxxxxx>, "aneesh@xxxxxx" <aneesh@xxxxxx>, "devicetree-discuss@xxxxxxxxxxxxxxxx" <devicetree-discuss@xxxxxxxxxxxxxxxx>, "linux-doc@xxxxxxxxxxxxxxx" <linux-doc@xxxxxxxxxxxxxxx>, "linux-kernel@xxxxxxxxxxxxxxx" <linux-kernel@xxxxxxxxxxxxxxx>, "linux-arm-kernel@xxxxxxxxxxxxxxxxxxx" <linux-arm-kernel@xxxxxxxxxxxxxxxxxxx>
- In-reply-to: <20120510214604.GA3525@kroah.com>
- Thread-index: Ac0vPars5f0RyuuyRmiFreZoTA8s8w==
- Thread-topic: [PATCH 3/4] ARM: tegra30: Add Tegra Memory Controller(MC) driver
Hi Greg,
From: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [PATCH 3/4] ARM: tegra30: Add Tegra Memory Controller(MC) driver
Date: Thu, 10 May 2012 23:46:04 +0200
Message-ID: <20120510214604.GA3525@xxxxxxxxx>
> On Thu, May 10, 2012 at 10:42:32AM +0300, Hiroshi DOYU wrote:
> > Tegra Memory Controller(MC) driver for Tegra30
> > Added to support MC General interrupts, mainly for IOMMU(SMMU).
>
> I'll apply this, but:
Thanks.
> > +static inline u32 mc_readl(struct tegra30_mc *mc, u32 offs)
> > +{
> > + if (offs < 0x10)
> > + return readl(mc->regs[0] + offs);
> > + BUG_ON(offs < 0x3c);
> > + if (offs < 0x1f0)
> > + return readl(mc->regs[1] + offs - 0x3c);
> > + BUG_ON(offs < 0x200);
> > + if (offs < 0x228)
> > + return readl(mc->regs[2] + offs - 0x200);
> > + BUG_ON(offs < 0x284);
> > + if (offs < 0x400)
> > + return readl(mc->regs[3] + offs - 0x284);
> > + BUG();
> > +}
>
> That's a lot of BUG* calls. Same thing with the 1/4 patch in this
> series.
>
> We really should not have a BUG call in any driver, as you just stopped
> the whole system. I can understand this being there for debugging when
> you create the code originally, but as these are things no one should
> ever be able to hit now, you should remove them, right?
>
> Care to write a follow-on patch removing all of these BUG_ON and BUG
> calls in this and the drivers/memory/tegra20-mc.c driver?
Ok, they are replying to this email.
--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[ARM Kernel]
[Linux USB Devel]
[Video for Linux]
[Linux Audio Users]
[Photo]
[Yosemite News]
[Yosemite Photos]
[Free Online Dating]
[Linux Kernel]
[Linux SCSI]
[XFree86]