From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Date: Tue, 26 Aug 2014 11:04:56 -0600 Subject: [U-Boot] [PATCH v2 01/40] vsprintf: Add modifier for phys_addr_t In-Reply-To: <1409067268-956-2-git-send-email-thierry.reding@gmail.com> References: <1409067268-956-1-git-send-email-thierry.reding@gmail.com> <1409067268-956-2-git-send-email-thierry.reding@gmail.com> Message-ID: <53FCBE38.9020304@wwwdotorg.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 08/26/2014 09:33 AM, Thierry Reding wrote: > From: Thierry Reding > > Provide a new modifier to vsprintf() to print phys_addr_t variables to > avoid having to cast or #ifdef when printing them out. The %pa modifier > is used for this purpose, so phys_addr_t variables need to be passed by > reference, like so: > > phys_addr_t start = 0; > > printf("start: %pa\n", &start); > > Depending on the size of phys_addr_t this will print out the address > with 8 or 16 hexadecimal digits following a 0x prefix. The series, Tested-by: Stephen Warren Note that I did see the following printed a couple of times when I executed "run bootcmd_pxe": pci_hose_bus_to_phys: invalid physical address ... but everything worked perfectly, so I guess we can track that down later.