From mboxrd@z Thu Jan 1 00:00:00 1970 From: Simon Schwarz Date: Thu, 28 Jul 2011 16:34:50 +0200 Subject: [U-Boot] [PATCH V6 2/5] omap-common: add nand spl support In-Reply-To: <4E317138.5010804@ti.com> References: <1311771039-31691-1-git-send-email-simonschwarzcor@gmail.com> <1311842291-24837-1-git-send-email-simonschwarzcor@gmail.com> <1311842291-24837-3-git-send-email-simonschwarzcor@gmail.com> <4E312EFE.1080900@ti.com> <4E3159B5.6090701@gmail.com> <4E317138.5010804@ti.com> Message-ID: <4E31738A.6050604@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Aneesh, On 07/28/2011 04:24 PM, Aneesh V wrote: > On Thursday 28 July 2011 06:14 PM, Simon Schwarz wrote: > [snip ..] > >>>> +#endif /* CONFIG_SPL_MMC_SUPPORT */ >>> >>> and here.. >>> >>> You start the same the #ifdef again immediately after the #endif. Why >>> don't you club them together into just one #ifdef block. >> IMHO #ifdef each function makes it more readable but... > > Ok. I don't have any strong views on that. > >> >>> >>> Actually, since we have garbage collection of un-used functions, I >>> think doing the calls under #ifdef should be enough, which you have >>> taken care in board_init_r(). That may help to avoid some #ifdef >>> clutter. >> ...I take this way :) >> >> I had to define some MMC specific stuff in the board config (copied it > > Does your board have MMC support? Then it definitely makes sense to > keep MMC support enabled. Yes it has MMC. If NAND works and is stable enough I will go for MMC. > >> from OMAP4 - not tested) and added __attribute__((unused)) to >> mmc_load_image to prevent the warning if the Library is not used. > > Did GCC give warning without this change? I think it doesn't due to > -ffunction-sections? It does issue warnings: spl.c:178:13: warning: 'mmc_load_image' defined but not used > > best regards, > Aneesh Regards Simon