From mboxrd@z Thu Jan 1 00:00:00 1970 From: Albert ARIBAUD Date: Sat, 15 Jan 2011 00:00:43 +0100 Subject: [U-Boot] [PATCH 0/4 V2] Add basic NVIDIA Tegra2 SoC support In-Reply-To: References: <1295025097-25680-1-git-send-email-twarren@nvidia.com> <1295035196.29642.6471.camel@petert> <1295041018.29642.6610.camel@petert> Message-ID: <4D30D59B.3000102@free.fr> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello, Le 14/01/2011 23:39, Tom Warren a ?crit : > So instead of, say uart->lcr = 0, you'd prefer writel(0, uart->lcr), > where writel = __arch_putl(v, a) = (*(volatile unsigned int *)(a) = > (v))? > Is that different enough from 'uart->lcr = 0' to warrant the change? > Does it add some HW barriers or forced read-before-write that the > 'volatile' struct doesn't? writel() and readl() do not introduce "read-before-write", that is, they do not perform any more than what their names imply, but yes they do introduce barriers, or more precisely, they force the compiler to do so. Amicalement, -- Albert.