From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marek Vasut Date: Wed, 19 Sep 2012 01:53:54 +0200 Subject: [U-Boot] [PATCHv4] [RFC] DM: early_malloc for DM added. In-Reply-To: References: <1346069529-27397-1-git-send-email-tmshlvck@gmail.com> <201209190133.09945.marex@denx.de> Message-ID: <201209190153.55058.marex@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 Graeme Russ, > Hi Marek, > > On Wed, Sep 19, 2012 at 9:33 AM, Marek Vasut wrote: > > Dear Graeme Russ, > > [snip] > > >> >> +struct early_heap_header *early_brk(size_t size) > >> >> + __attribute__((weak, alias("def_early_brk"))); > >> > > >> > what about using (it needs ): > >> > > >> > __weak struct early_heap_header *early_brk(size_t size) > >> > { > >> > ... > >> > body > >> > ... > >> > } > >> > >> We already have a lot of the former - I prefer not to add additional > >> semantics (unless you want to do a wholesale search/replace ;)) > > > > The former looks like shit and the later is more linux-friendly. I'd say > > stick with the later to avoid this insane __attribute__(()) construct. > > I agree, but, consistently bad is worse than inconsistently bad :) To weed out the old crap, we need linux/compiler.h enabled across whole uboot ... it's in the todo. > I'm look forward to reviewing a cleanup patch ;) Wait until I get it completely built. linux/compiler.h causes breakage on some ancient PPC crap. > Regards, > > Graeme Best regards, Marek Vasut