* [U-Boot] [PATCH 1/1] omap: Omit fastboot.userdata_size related errors
@ 2017-09-21 20:01 Sam Protsenko
2017-10-07 13:08 ` [U-Boot] [U-Boot, " Tom Rini
0 siblings, 1 reply; 2+ messages in thread
From: Sam Protsenko @ 2017-09-21 20:01 UTC (permalink / raw)
To: u-boot
When using regular $partitions variable (for Linux boot), we can see
some unwanted messages:
> ERROR: cannot find partition: 'userdata'
> at arch/arm/mach-omap2/utils.c:96/omap_mmc_get_part_size()
> Warning: fastboot.userdata_size: unable to calc
Let's remove those, as missing 'userdata' partition is correct behavior
for Linux partition, and we don't want to see some Android-related
messages in this case.
Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
---
arch/arm/mach-omap2/utils.c | 13 ++++---------
1 file changed, 4 insertions(+), 9 deletions(-)
diff --git a/arch/arm/mach-omap2/utils.c b/arch/arm/mach-omap2/utils.c
index 0b0bf1837c..3892853c7e 100644
--- a/arch/arm/mach-omap2/utils.c
+++ b/arch/arm/mach-omap2/utils.c
@@ -92,10 +92,8 @@ static u32 omap_mmc_get_part_size(const char *part)
}
res = part_get_info_by_name(dev_desc, part, &info);
- if (res < 0) {
- error("cannot find partition: '%s'\n", part);
+ if (res < 0)
return 0;
- }
/* Calculate size in bytes */
sz = (info.size * (u64)info.blksz);
@@ -111,13 +109,10 @@ static void omap_set_fastboot_userdata_size(void)
u32 sz_kb;
sz_kb = omap_mmc_get_part_size("userdata");
- if (sz_kb == 0) {
- buf[0] = '\0';
- printf("Warning: fastboot.userdata_size: unable to calc\n");
- } else {
- sprintf(buf, "%u", sz_kb);
- }
+ if (sz_kb == 0)
+ return; /* probably it's not Android partition table */
+ sprintf(buf, "%u", sz_kb);
env_set("fastboot.userdata_size", buf);
}
#else
--
2.14.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [U-Boot] [U-Boot, 1/1] omap: Omit fastboot.userdata_size related errors
2017-09-21 20:01 [U-Boot] [PATCH 1/1] omap: Omit fastboot.userdata_size related errors Sam Protsenko
@ 2017-10-07 13:08 ` Tom Rini
0 siblings, 0 replies; 2+ messages in thread
From: Tom Rini @ 2017-10-07 13:08 UTC (permalink / raw)
To: u-boot
On Thu, Sep 21, 2017 at 11:01:00PM +0300, Sam Protsenko wrote:
> When using regular $partitions variable (for Linux boot), we can see
> some unwanted messages:
>
> > ERROR: cannot find partition: 'userdata'
>
> > at arch/arm/mach-omap2/utils.c:96/omap_mmc_get_part_size()
> > Warning: fastboot.userdata_size: unable to calc
>
> Let's remove those, as missing 'userdata' partition is correct behavior
> for Linux partition, and we don't want to see some Android-related
> messages in this case.
>
> Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
Applied to u-boot/master, thanks!
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171007/4018e3d3/attachment.sig>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-10-07 13:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-21 20:01 [U-Boot] [PATCH 1/1] omap: Omit fastboot.userdata_size related errors Sam Protsenko
2017-10-07 13:08 ` [U-Boot] [U-Boot, " Tom Rini
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.