From: Wolfgang Denk Date: Fri, 28 Oct 2011 22:19:50 +0200 Subject: [U-Boot] [PATCH] e1000: fix bugs from recent commits In-Reply-To: References: <1318971929-1160-1-git-send-email-Kyle.D.Moffett@boeing.com> <1319780953-10594-1-git-send-email-wd@denx.de> Message-ID: <20111028201950.191081809855@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Mike Frysinger, In message you wrote: > On Fri, Oct 28, 2011 at 07:49, Wolfgang Denk wrote: > > --- a/drivers/net/e1000.h > > +++ b/drivers/net/e1000.h > > > > #define E1000_WRITE_FLUSH(a) \ > > - do { uint32_t x = E1000_READ_REG(a, STATUS); } while (0) > > + E1000_READ_REG(a, STATUS) > > i think we want the do{}while as this is a write command and we don't > want people accidentally trying to check the return value I don't see that this is a write command. I'm seeing only reading of the status register here. And I don't understand the "accidentally trying to check the return value" argument either. Why would one do that - and if one does (probably after checking the implementation), what would be wrong about it? Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de My play was a complete success. The audience was a failure.