[U-Boot] [PATCH v2 0/9] reduce the size of the mmc core
Joakim Tjernlund
Joakim.Tjernlund at infinera.com
Thu Jan 4 14:43:02 UTC 2018
On Thu, 2018-01-04 at 15:23 +0100, Jean-Jacques Hiblot wrote:
> CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
>
>
> This series applies on u-boot/next
>
> It aims at reducing the size taken by the mmc core in the SPL.
> Recent changes (for which I'm to blame) have bloated the mmc core and have
> broken platforms that were already tight on code space. This is achieved mostly
> by compiling out parts of the initialization process that are not required when
> the SD/MMC write operations are not used.
I have not looked at the code so maybe this off ...
You can save a lot of space/code if you avoid static/global variables.
Instead of
#define MYSTR "some cool feature"
static char *mystr = MYSTR;
do
fun()
{
char *mystr = MYSTR;
...
}
Avoid static/global vars at all cost!
Jocke
More information about the U-Boot
mailing list