[U-Boot] [PATCH 1/6] fdtdec: allow board to provide fdt for CONFIG_OF_SEPARATE

2017-08-03 Thread Rob Clark
/aboot), which patches the fdt and passes it back to u-boot. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/fdtdec.h | 3 ++- lib/fdtdec.c | 45 ++--- 2 files changed, 28 insertions(+), 20 deletions(-) diff --git a/include/fdtd

[U-Boot] [PATCH 2/3] video: simplefb

2017-08-03 Thread Rob Clark
Not really qcom specific, but for now qcom/lk is the one firmware that is (afaiu) setting up the appropriate dt node for pre-configured display. Uses the generic simple-framebuffer DT bindings so this should be useful on other platforms. Signed-off-by: Rob Clark <robdcl...@gmail.

[U-Boot] [PATCH 3/3] video: add config option to skip framebuffer clear

2017-08-03 Thread Rob Clark
The use-case is that the thing that loaded u-boot already put a splash image on screen. And we want to preserve that until grub boot menu takes over. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- drivers/video/Kconfig| 8 drivers/video/cfb_console.c | 3 ++- drivers

[U-Boot] [PATCH 1/3] dm: core: also parse chosen node

2017-08-03 Thread Rob Clark
This is the node that would contain, for example, the framebuffer setup by an earlier stage. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- drivers/core/root.c | 22 +- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/drivers/core/root.c b/drivers/core/

Re: [U-Boot] [PATCH] dm: core: don't fail to iterate if first one fails to probe

2017-08-03 Thread Rob Clark
On Thu, Aug 3, 2017 at 11:24 AM, Simon Glass <s...@chromium.org> wrote: > Hi Rob, > > On 19 July 2017 at 10:53, Rob Clark <robdcl...@gmail.com> wrote: >> On Thu, Jul 13, 2017 at 3:10 PM, Simon Glass <s...@chromium.org> wrote: >>> Hi Rob, >>&

[U-Boot] [PATCH 1/2] usb: kbd: don't fail with iomux

2017-08-03 Thread Rob Clark
stdin might not be set, which would cause iomux_doenv() to fail therefore causing probe_usb_keyboard() to fail. Furthermore if we do have iomux enabled, the sensible thing (in terms of user experience) would be to simply add ourselves to the list of stdin devices. Signed-off-by: Rob Clark

Re: [U-Boot] [RFC] C2011 standard for building U-Boot

2017-08-03 Thread Rob Clark
Thanks Heinrich Just for everyone else's information, the background is that a UEFI implementation *really* wants utf16, and this suggestion avoids needing -fshort-wchar globally (or a lot of clumsiness in efi_loader) BR, -R On Thu, Aug 3, 2017 at 12:27 AM, Heinrich Schuchardt

Re: [U-Boot] [PATCH] vsprintf.c: add wide string (%ls) support

2017-08-02 Thread Rob Clark
On Wed, Aug 2, 2017 at 5:40 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 08/02/2017 08:15 PM, Rob Clark wrote: >> On Wed, Aug 2, 2017 at 1:05 PM, Heinrich Schuchardt <xypron.g...@gmx.de> >> wrote: >>> On 08/02/2017 11:38 AM, Rob Clark wrote:

Re: [U-Boot] [PATCH] vsprintf.c: add wide string (%ls) support

2017-08-02 Thread Rob Clark
On Wed, Aug 2, 2017 at 1:05 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 08/02/2017 11:38 AM, Rob Clark wrote: >> On Tue, Aug 1, 2017 at 10:22 PM, Heinrich Schuchardt <xypron.g...@gmx.de> >> wrote: >>> On 07/31/2017 02:42 PM, Rob Clark wrote: &g

Re: [U-Boot] [PATCH] efi_loader: make pool allocations cacheline aligned

2017-08-02 Thread Rob Clark
On Wed, Aug 2, 2017 at 11:24 AM, BrĂ¼ns, Stefan <stefan.bru...@rwth-aachen.de> wrote: > On Mittwoch, 2. August 2017 11:28:37 CEST Rob Clark wrote: >> On Tue, Aug 1, 2017 at 9:10 PM, Heinrich Schuchardt > [...] >> >> >> >> @@ -356,7 +356,8 @@ ef

Re: [U-Boot] [PATCH] vsprintf.c: add wide string (%ls) support

2017-08-02 Thread Rob Clark
On Tue, Aug 1, 2017 at 10:22 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/31/2017 02:42 PM, Rob Clark wrote: >> This is convenient for efi_loader which deals a lot with utf16. >> >> Signed-off-by: Rob Clark <robdcl...@gmail.com&g

Re: [U-Boot] [PATCH] efi_loader: make pool allocations cacheline aligned

2017-08-02 Thread Rob Clark
On Tue, Aug 1, 2017 at 9:10 PM, Heinrich Schuchardt <xypron.deb...@gmx.de> wrote: > On 08/01/2017 10:00 PM, Rob Clark wrote: >> This avoids printf() spam about file reads (such as loading an image) >> into unaligned buffers (and the associated memcpy()). And generally >

[U-Boot] [PATCH] efi_loader: make pool allocations cacheline aligned

2017-08-01 Thread Rob Clark
This avoids printf() spam about file reads (such as loading an image) into unaligned buffers (and the associated memcpy()). And generally seems like a good idea. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_memory.c | 5 +++-- 1 file changed, 3 insertions

[U-Boot] [PATCH] vsprintf.c: add wide string (%ls) support

2017-07-31 Thread Rob Clark
This is convenient for efi_loader which deals a lot with utf16. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/vsprintf.c | 39 +-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/lib/vsprintf.c b/lib/vsprintf.c index 874a

Re: [U-Boot] [PATCH 4/4] efi_loader: indent entry/exit prints to show nesting level

2017-07-28 Thread Rob Clark
On Fri, Jul 28, 2017 at 6:22 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 28.07.17 12:11, Rob Clark wrote: >> >> On Fri, Jul 28, 2017 at 5:36 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 28.07.17 1

Re: [U-Boot] [PATCH 4/4] efi_loader: indent entry/exit prints to show nesting level

2017-07-28 Thread Rob Clark
On Fri, Jul 28, 2017 at 5:36 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 28.07.17 11:34, Rob Clark wrote: >> >> On Fri, Jul 28, 2017 at 5:25 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 28.07.17 1

Re: [U-Boot] [PATCH 4/4] efi_loader: indent entry/exit prints to show nesting level

2017-07-28 Thread Rob Clark
On Fri, Jul 28, 2017 at 5:25 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 28.07.17 11:19, Rob Clark wrote: >> >> On Fri, Jul 28, 2017 at 3:24 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 27.07.17 14:04, R

Re: [U-Boot] [PATCH 4/4] efi_loader: indent entry/exit prints to show nesting level

2017-07-28 Thread Rob Clark
On Fri, Jul 28, 2017 at 3:24 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 27.07.17 14:04, Rob Clark wrote: >> >> This should make it easier to see when a callback back to UEFI world >> calls back in to the u-boot world, and generally match up EFI_ENTRY() >

Re: [U-Boot] [RFC 10/10] efi_loader: support load_image() from a file-path

2017-07-27 Thread Rob Clark
On Thu, Jul 27, 2017 at 5:38 PM, Rob Clark <robdcl...@gmail.com> wrote: > Previously we only supported the case when the EFI application loaded > the image into memory for us. But fallback.efi does not do this. > > Signed-off-by: Rob Clark <robdcl...@gmail.com>

[U-Boot] [RFC 10/10] efi_loader: support load_image() from a file-path

2017-07-27 Thread Rob Clark
Previously we only supported the case when the EFI application loaded the image into memory for us. But fallback.efi does not do this. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_boottime.c | 91 --- 1 file changed, 76 inse

[U-Boot] [RFC 08/10] efi_loader: refactor boot device and loaded_image handling

2017-07-27 Thread Rob Clark
things in properly to the loaded_image. In a following patch we'll want to re-use this in efi_load_image() to handle the case of loading an image from a file_path. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- cmd/bootefi.c | 163 +- i

[U-Boot] [RFC 06/10] efi_loader: use proper device-paths for partitions

2017-07-27 Thread Rob Clark
Peter Jones, but re-worked to use efi_device_path, so it doesn't much resemble the original. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_disk.c | 52 +++ 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/lib/e

[U-Boot] [RFC 02/10] efi: fill in disk signature bits of hard drive device path.

2017-07-27 Thread Rob Clark
From: Peter Jones EFI client programs need the signature information from the partition table to determine the disk a partition is on, so we need to fill that in here. Signed-off-by: Peter Jones --- disk/part_dos.c| 12 +--- disk/part_efi.c

[U-Boot] [RFC 09/10] efi_loader: add file/filesys support

2017-07-27 Thread Rob Clark
fallback.efi (and probably other things) use UEFI's simple-file-system protocol and file support to search for OS's to boot. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- fs/fs.c | 21 ++ include/efi.h | 2 + include/efi

[U-Boot] [RFC 07/10] efi_loader: use proper device-paths for net

2017-07-27 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 2 +- lib/efi_loader/efi_net.c | 24 +++- 2 files changed, 4 insertions(+), 22 deletions(-) diff --git a/include/efi_loader.h b/include/efi_loader.h index f09d0a8003..c5cc15fc4c

[U-Boot] [RFC 05/10] efi_loader: add device-path utils

2017-07-27 Thread Rob Clark
it, but slightly more convincingly. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 17 ++ lib/efi_loader/Makefile | 2 +- lib/efi_loader/efi_device_path.c | 408 +++ 3 files changed, 426 insertions(+), 1 de

[U-Boot] [RFC 04/10] fs: add fs_readdir()

2017-07-27 Thread Rob Clark
Needed to support efi file protocol. The fallback.efi loader wants to be able to read the contents of the /EFI directory to find an OS to boot. Currently only implemented for FAT, but that is all that UEFI is required to support. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- fs/fat

[U-Boot] [RFC 03/10] efi: add some more device path structures

2017-07-27 Thread Rob Clark
From: Peter Jones Signed-off-by: Peter Jones --- include/efi_api.h | 49 +++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/include/efi_api.h b/include/efi_api.h index ec1b321e8e..85afbeb72b

[U-Boot] [RFC 01/10] efi_loader: add back optional efi_handler::open()

2017-07-27 Thread Rob Clark
;old way" are, and which do not need this extra complexity, are rebased. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 12 +++- lib/efi_loader/efi_boottime.c | 30 -- 2 files changed, 35 insertions(+), 7 delet

[U-Boot] [RFC 00/10] efi_loader: bunch of EFI work for distro boot

2017-07-27 Thread Rob Clark
shim.efi or grubaa64.efi. (Once I have support to write variables and saveenv in ExitBootServices then it should only hit fallback.efi on first boot.) Peter Jones (2): efi: fill in disk signature bits of hard drive device path. efi: add some more device path structures Rob Clark (8

[U-Boot] [PATCH] efi_loader: add some missing breaks

2017-07-27 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- Just noticed that there didn't seem to be quite enough break's. Pretty sure the intention wasn't to fall-thru lib/efi_loader/efi_device_path_to_text.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/efi_

[U-Boot] [PATCH 4/4] efi_loader: indent entry/exit prints to show nesting level

2017-07-27 Thread Rob Clark
This should make it easier to see when a callback back to UEFI world calls back in to the u-boot world, and generally match up EFI_ENTRY() and EFI_EXIT() calls. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 12 lib/efi_loader/efi_boottime.

[U-Boot] [PATCH 3/4] efi_loader: add checking for incorrect use of EFI_ENTRY/EXIT

2017-07-27 Thread Rob Clark
Missing an EFI_ENTRY() or doubling up EFI_EXIT() leads to non-obvious crashes. Let's add some error checking. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 17 +--- lib/efi_loader/efi_boottime.c | 45 +---

[U-Boot] [PATCH 2/4] efi_loader: Add an EFI_CALL() macro

2017-07-27 Thread Rob Clark
Rather than open-coding EFI_EXIT() + callback + EFI_ENTRY(), introduce an EFI_CALL() macro. This makes callbacks into UEFI world (of which there will be more in the future) more concise and easier to locate in the code. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_lo

[U-Boot] [PATCH 1/4] efi_loader: only evaluate EFI_EXIT()'s ret once

2017-07-27 Thread Rob Clark
There are a couple spots doing things like: return EFI_EXIT(some_fxn(...)); which I handn't noticed before. With addition of printing return value in the EFI_EXIT() macro, now the fxn call was getting evaluated twice. Which we didn't really want. Signed-off-by: Rob Clark <rob

Re: [U-Boot] [PATCH 2/3] efi_loader: add checking for incorrect use of EFI_ENTRY/EXIT

2017-07-26 Thread Rob Clark
On Wed, Jul 26, 2017 at 4:12 PM, Alexander Graf <ag...@suse.de> wrote: > > > On 26.07.17 18:41, Rob Clark wrote: >> >> On Wed, Jul 26, 2017 at 11:25 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 26.07.17 15:55,

Re: [U-Boot] [PATCH] efi_loader: fix bug in efi_get_memory_map

2017-07-26 Thread Rob Clark
On Wed, Jul 26, 2017 at 4:10 PM, Alexander Graf <ag...@suse.de> wrote: > > > On 26.07.17 20:34, Rob Clark wrote: >> >> When booting shim -> fallback -> shim -> grub -> linux the memory map is >> a bit larger than the size linux passes in on the first c

[U-Boot] [PATCH] efi_loader: only evaluate EFI_EXIT()'s ret once

2017-07-26 Thread Rob Clark
There are a couple spots doing things like: return EFI_EXIT(some_fxn(...)); which I handn't noticed before. With addition of printing return value in the EFI_EXIT() macro, now the fxn call was getting evaluated twice. Which we didn't really want. Signed-off-by: Rob Clark <rob

[U-Boot] [PATCH] efi_loader: fix bug in efi_get_memory_map

2017-07-26 Thread Rob Clark
When booting shim -> fallback -> shim -> grub -> linux the memory map is a bit larger than the size linux passes in on the first call. But in the EFI_BUFFER_TOO_SMALL case we were not passing back the updated size to linux so it would loop forever. Signed-off-by: Rob Clark <robd

Re: [U-Boot] [PATCH 2/3] efi_loader: add checking for incorrect use of EFI_ENTRY/EXIT

2017-07-26 Thread Rob Clark
On Wed, Jul 26, 2017 at 11:25 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 26.07.17 15:55, Rob Clark wrote: >> >> Missing an EFI_ENTRY() or doubling up EFI_EXIT() leads to non-obvious >> crashes. Let's add some error checking. >> >>

[U-Boot] [PATCH 2/3] efi_loader: add checking for incorrect use of EFI_ENTRY/EXIT

2017-07-26 Thread Rob Clark
Missing an EFI_ENTRY() or doubling up EFI_EXIT() leads to non-obvious crashes. Let's add some error checking. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 5 + lib/efi_loader/efi_boottime.c | 13 + 2 files changed, 18 insertions(+)

[U-Boot] [PATCH 3/3] efi_loader: indent entry/exit prints to show nesting level

2017-07-26 Thread Rob Clark
This should make it easier to see when a callback back to UEFI world calls back in to the u-boot world, and generally match up EFI_ENTRY() and EFI_EXIT() calls. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 12 lib/efi_loader/efi_boottime.

[U-Boot] [PATCH 1/3] efi_loader: Add an EFI_CALL() macro

2017-07-26 Thread Rob Clark
Rather than open-coding EFI_EXIT() + callback + EFI_ENTRY(), introduce an EFI_CALL() macro. This makes callbacks into UEFI world (of which there will be more in the future) more concise and easier to locate in the code. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_lo

[U-Boot] [PATCH] efi_loader: remove more double EFI_EXIT() in efi_disk.c

2017-07-25 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_disk.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/efi_loader/efi_disk.c b/lib/efi_loader/efi_disk.c index adf906b7dd..4bde2287b4 100644 --- a/lib/efi_loader/efi_disk.c +++ b/lib/efi_

[U-Boot] [PATCH] efi_loader: remove double EFI_EXIT() with efi_unsupported

2017-07-25 Thread Rob Clark
Probably this went unnoticed before, but it causes problems with addition of 804b1d73 ("efi_loader: log EFI return values too") Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_boottime.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 6:10 PM, Alexander Graf <ag...@suse.de> wrote: > > > On 26.07.17 00:01, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 5:42 PM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 25.07.17 23:26, Rob

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 5:42 PM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 23:26, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 5:01 PM, Heinrich Schuchardt <xypron.g...@gmx.de> >> wrote: >>> >>> On 07/25/2017 09:42 PM, R

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 5:01 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/25/2017 09:42 PM, Rob Clark wrote: >> On Tue, Jul 25, 2017 at 3:12 PM, Heinrich Schuchardt <xypron.g...@gmx.de> >> wrote: >>> On 07/25/2017 07:52 PM, Rob Clark wrote: &

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 3:12 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/25/2017 07:52 PM, Rob Clark wrote: >> On Tue, Jul 25, 2017 at 12:56 PM, Heinrich Schuchardt >> <xypron.g...@gmx.de> wrote: >>> On 07/25/2017 04:28 PM, Alexander Graf wro

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 12:56 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/25/2017 04:28 PM, Alexander Graf wrote: >> >> >> On 25.07.17 14:28, Rob Clark wrote: >>> On Tue, Jul 25, 2017 at 8:16 AM, Alexander Graf <ag...@suse.de> wrote: &

Re: [U-Boot] [RFC] efi: variable support

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 1:29 PM, Alexander Graf <ag...@suse.de> wrote: > > >> Am 25.07.2017 um 19:23 schrieb Rob Clark <robdcl...@gmail.com>: >> >>> On Tue, Jul 25, 2017 at 12:55 PM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >

Re: [U-Boot] [RFC] efi: variable support

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 12:55 PM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 17:47, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 10:25 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 25.07.17 1

Re: [U-Boot] [PATCH] efi_loader: add back optional efi_handler::open()

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 12:39 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/25/2017 02:21 PM, Rob Clark wrote: >> In some cases it is useful to defer creation of the protocol interface >> object. So add back an optional ->open() hook that is used if >

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 10:28 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 14:28, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 8:16 AM, Alexander Graf <ag...@suse.de> wrote: >> >>> I personally think having _ext functions in anythi

Re: [U-Boot] [RFC] efi: variable support

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 10:25 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 14:47, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 5:38 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> I agree :). We still want to have overr

Re: [U-Boot] [PATCH 2/4] efi_loader: add udevice to EFI device-path mapping

2017-07-25 Thread Rob Clark
semi-reasonable? I'm not sure if this intersects too badly with other stuff Heinrich is working on? (Also, small logistical question.. anyone know how to do "obj-$(!CONFIG_DM) += efi_boot_device_legacy.o"?) BR, -R On Fri, Jul 21, 2017 at 2:43 PM, Rob Clark <robdcl...@gmail.com> wr

Re: [U-Boot] [RFC] efi: variable support

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 5:38 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 19.07.17 18:38, Rob Clark wrote: >> >> On Wed, Jul 12, 2017 at 8:57 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 25.06.17 00:2

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 8:16 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 14:08, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 7:17 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 25.07.17 1

[U-Boot] [PATCH] efi_loader: add back optional efi_handler::open()

2017-07-25 Thread Rob Clark
;old way" are, and which do not need this extra complexity, are rebased. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- v2: also handle this properly in locate_protocol as agraf pointed out Note that I might be misunderstanding what the EFI application expects when looking up de

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 7:17 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 13:10, Rob Clark wrote: >> >> On Tue, Jul 25, 2017 at 4:10 AM, Alexander Graf <ag...@suse.de> wrote: >>> >>> >>> >>> On 25.07.

Re: [U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-25 Thread Rob Clark
On Tue, Jul 25, 2017 at 4:10 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.07.17 01:47, Rob Clark wrote: >> >> To implement efi_load_image() for the case of loading an image from a >> device path rather than image already loaded into source_buffer, it is &

[U-Boot] [PATCH] efi_loader: allow efi_loader code to call EFI interfaces

2017-07-24 Thread Rob Clark
interfaces to be recursive, since this greatly simplifies things. (And hypothetically this would be needed anyways to allow grub to call into interfaces installed by something outside of grub.) Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_boottime.c | 5 + 1 file chan

Re: [U-Boot] efi_loader: workaround for grub lsefi bug

2017-07-24 Thread Rob Clark
On Mon, Jul 24, 2017 at 2:31 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/20/2017 01:59 PM, Rob Clark wrote: >> Patch has also been sent to fix grub to not ignore the error returned >> and treat protocol_buffer_count as valid. But that that might take

Re: [U-Boot] [PATCH v2 01/12] efi_loader: refactor efi_open_protocol

2017-07-24 Thread Rob Clark
On Mon, Jul 24, 2017 at 1:11 PM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/24/2017 11:48 AM, Rob Clark wrote: >> On Tue, Jul 11, 2017 at 4:06 PM, Heinrich Schuchardt <xypron.g...@gmx.de> >> wrote: >>> efi_open_protocol was implemented to call a

[U-Boot] [PATCH 2/2] efi_loader: expose protocols via GUID

2017-07-24 Thread Rob Clark
shim.efi (or rather gnu-efi's LibLocateProtocol() which shim.efi uses) resolves protocols via efi_locate_handle() so the console protocols need to be added to the efi object list. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_api.h| 9 + include/efi_lo

[U-Boot] [PATCH 1/2] efi_loader: add helper macro to construct protocol objects

2017-07-24 Thread Rob Clark
dle that LocateHandle() returns.. See LibLocateProtocol() in gnu-efi. It does LocateHandle() to find all the handles, and then loops over them calling HandleProtocol() with the GUID of the protocol it is trying to find. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loa

[U-Boot] [PATCH] efi_loader: add back optional efi_handler::open()

2017-07-24 Thread Rob Clark
;old way" are, and which do not need this extra complexity, are rebased. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 9 - lib/efi_loader/efi_boottime.c | 7 +++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/include/efi

[U-Boot] [PATCH] efi_loader: log EFI return values too

2017-07-24 Thread Rob Clark
Turns out this is rather useful to tracking down where things fail. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- v2: use EFI_ERROR_MASK include/efi_loader.h | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/efi_loader.h b/include/efi_loader.h index 40e0

Re: [U-Boot] [PATCH] efi_loader: log EFI return values too

2017-07-24 Thread Rob Clark
On Mon, Jul 24, 2017 at 8:36 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 24.07.17 13:59, Rob Clark wrote: >> >> Turns out this is rather useful to tracking down where things fail. >> >> Signed-off-by: Rob Clark <robdcl...@gmail.com> >

[U-Boot] [PATCH] efi_loader: move guidcmp to header

2017-07-24 Thread Rob Clark
Want to re-use this for file protocol, which I'm working on. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h | 5 + lib/efi_loader/efi_boottime.c | 5 - 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/efi_loader.h b/i

[U-Boot] [PATCH] efi_loader: log EFI return values too

2017-07-24 Thread Rob Clark
Turns out this is rather useful to tracking down where things fail. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- I've been carrying this around locally for a while.. but I find it useful and I expect others would too. include/efi_loader.h | 5 - 1 file changed, 4 insertions

[U-Boot] [PATCH] efi_loader: EFI file paths should be DOS style

2017-07-24 Thread Rob Clark
shim.efi, for example, actually tries to parse this, but is expecting backslashes. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- cmd/bootefi.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cmd/bootefi.c b/cmd/bootefi.c index b6d5047301..689eb09942 100644 ---

Re: [U-Boot] [PATCH v2 01/12] efi_loader: refactor efi_open_protocol

2017-07-24 Thread Rob Clark
On Tue, Jul 11, 2017 at 4:06 PM, Heinrich Schuchardt wrote: > efi_open_protocol was implemented to call a protocol specific open > function to retrieve the protocol interface. > > The UEFI specification does not know of such a function. > > It is not possible to implement

Re: [U-Boot] [U-Boot, 3/4] efi_loader: make disk objects for partitions

2017-07-23 Thread Rob Clark
On Sun, Jul 23, 2017 at 6:25 AM, Heinrich Schuchardt <xypron.g...@gmx.de> wrote: > On 07/21/2017 08:43 PM, Rob Clark wrote: >> Normally a EFI application, like grub2, is going to expect to see > > %s/a/an/ > >> block-io devices for both the actual disk and for ea

Re: [U-Boot] [PATCH 5/5] db410c: config updates

2017-07-21 Thread Rob Clark
On Fri, Jul 21, 2017 at 6:20 PM, Tom Rini <tr...@konsulko.com> wrote: > On Fri, Jul 21, 2017 at 03:10:14PM -0400, Rob Clark wrote: >> Signed-off-by: Rob Clark <robdcl...@gmail.com> >> --- >> arch/arm/Kconfig | 2 +- >> configs/dragonboard

Re: [U-Boot] [PATCH 1/5] Makefile: also build fdt for snapdragon

2017-07-21 Thread Rob Clark
On Fri, Jul 21, 2017 at 6:18 PM, Tom Rini <tr...@konsulko.com> wrote: > On Fri, Jul 21, 2017 at 03:10:10PM -0400, Rob Clark wrote: > >> Snapdragon is a bit of a funny case, where we want to build the fdt to >> pass to lk, which loads us, but otherwise want to treat it

[U-Boot] [PATCH] db410c: enable r8152 usb eth

2017-07-21 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- I figured out why I was having no luck getting my usb ethernet dongle to work ;-) include/configs/dragonboard410c.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/configs/dragonboard410c.h b/include/configs/dragonboard410c.h

[U-Boot] [PATCH 1/2] usb: kbd: don't fail with iomux

2017-07-21 Thread Rob Clark
stdin might not be set, which would cause iomux_doenv() to fail therefore causing probe_usb_keyboard() to fail. Furthermore if we do have iomux enabled, the sensible thing (in terms of user experience) would be to simply add ourselves to the list of stdin devices. Signed-off-by: Rob Clark

[U-Boot] [PATCH 2/2] usb: kbd: add missing \n

2017-07-21 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- common/usb_kbd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/usb_kbd.c b/common/usb_kbd.c index 72cf78abd4..615f8f88cd 100644 --- a/common/usb_kbd.c +++ b/common/usb_kbd.c @@ -654,7 +654,7 @@ stat

[U-Boot] [PATCH 5/5] db410c: config updates

2017-07-21 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- arch/arm/Kconfig | 2 +- configs/dragonboard410c_defconfig | 8 +++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index f7b44392ac..db6a325ee1 100644 --- a/ar

[U-Boot] [PATCH 4/5] db410c: on aarch64 the fdtfile is in per-vendor subdirectory

2017-07-21 Thread Rob Clark
Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/configs/dragonboard410c.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/configs/dragonboard410c.h b/include/configs/dragonboard410c.h index 11c842d952..8e742d82ce 100644 --- a/include/c

[U-Boot] [PATCH 1/5] Makefile: also build fdt for snapdragon

2017-07-21 Thread Rob Clark
Snapdragon is a bit of a funny case, where we want to build the fdt to pass to lk, which loads us, but otherwise want to treat it as OF_BOARD, since lk will patch the fdt (for example, to insert simple-framebuffer node). Signed-off-by: Rob Clark <robdcl...@gmail.com> --- Makefile | 6 +++

[U-Boot] [PATCH 3/5] db410c: add reserved-memory node to dts

2017-07-21 Thread Rob Clark
If lk lights up display and populates simple-framebuffer node, it will also setup a reserved-memory node (needed by simplefb on linux). But it isn't clever enough to cope when the reserved-memory node is not present. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- arch/a

[U-Boot] [PATCH 2/5] db410c: use fdt passed from lk

2017-07-21 Thread Rob Clark
lk patches the fdt to set some device's MAC addresses and more importantly to patch in the simple-framebuffer node that we want u-boot to see. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- board/qualcomm/dragonboard410c/Makefile | 1 + board/qualcomm/dragonboa

[U-Boot] [PATCH 0/5] dragonboard 410c patches

2017-07-21 Thread Rob Clark
Rob Clark (5): Makefile: also build fdt for snapdragon db410c: use fdt passed from lk db410c: add reserved-memory node to dts db410c: on aarch64 the fdtfile is in per-vendor subdirectory db410c: config updates Makefile | 6 arch/arm/Kconfig

[U-Boot] [PATCH 3/3] video: add config option to skip framebuffer clear

2017-07-21 Thread Rob Clark
The use-case is that the thing that loaded u-boot already put a splash image on screen. And we want to preserve that until grub boot menu takes over. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- drivers/video/Kconfig| 8 drivers/video/cfb_console.c | 3 ++- drivers

[U-Boot] [PATCH 1/3] dm: core: also parse chosen node

2017-07-21 Thread Rob Clark
This is the node that would contain, for example, the framebuffer setup by an earlier stage. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- drivers/core/root.c | 22 +- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/drivers/core/root.c b/drivers/core/

[U-Boot] [PATCH 4/4] efi_loader: use efi_devpath to get correct boot device-path

2017-07-21 Thread Rob Clark
This way grub can properly match up the loaded_image device-path to a partition device object, so it can locate it's grub.cfg. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- cmd/bootefi.c | 31 ++- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git

[U-Boot] [PATCH 1/4] efi: add some more device path structures

2017-07-21 Thread Rob Clark
From: Peter Jones Signed-off-by: Peter Jones --- include/efi_api.h | 49 +++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/include/efi_api.h b/include/efi_api.h index f071b36b53..e1b3f11c6d

[U-Boot] [PATCH 2/4] efi_loader: add udevice to EFI device-path mapping

2017-07-21 Thread Rob Clark
Initially just supports "disk" type devices, but a real UEFI implementation would expose input/output/display/etc with device-paths as well, so we may eventually want to expand this for other uses. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- include/efi_loader.h

[U-Boot] [PATCH 3/4] efi_loader: make disk objects for partitions

2017-07-21 Thread Rob Clark
(config issue?) so I haven't been able to test the net-boot path.. so it likely needs some work. Cc: Peter Jones <pjo...@redhat.com> Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_disk.c | 73 ++- 1 file changed, 53 inser

[U-Boot] [PATCH 0/4] efi_loader: fix disk objects + device-paths

2017-07-21 Thread Rob Clark
and tried to minimize the ifdeffery, but things will get much cleaner when legacy support is removed. Peter Jones (1): efi: add some more device path structures Rob Clark (3): efi_loader: add udevice to EFI device-path mapping efi_loader: make disk objects for partitions efi_loader: use efi_devp

Re: [U-Boot] [PATCH 4/5] efi_loader: gop: fixes for CONFIG_DM_VIDEO without CONFIG_LCD

2017-07-21 Thread Rob Clark
On Fri, Jul 21, 2017 at 11:58 AM, Tom Rini <tr...@konsulko.com> wrote: > On Fri, Jul 21, 2017 at 04:48:23AM -0600, Simon Glass wrote: >> Hi Rob, >> >> On 19 July 2017 at 09:24, Rob Clark <robdcl...@gmail.com> wrote: >> > On Tue, Jul 18, 2017 at 11:0

Re: [U-Boot] [PATCH 4/5] efi_loader: gop: fixes for CONFIG_DM_VIDEO without CONFIG_LCD

2017-07-21 Thread Rob Clark
lass wrote: >>>> >>>> Hi, >>>> >>>> On 12 July 2017 at 05:52, Alexander Graf <ag...@suse.de> wrote: >>>>> >>>>> >>>>> On 25.06.17 01:05, Rob Clark wrote: >>>>>> >>>>&g

[U-Boot] [PATCH] efi_loader: workaround for grub lsefi bug

2017-07-20 Thread Rob Clark
Patch has also been sent to fix grub to not ignore the error returned and treat protocol_buffer_count as valid. But that that might take a while to trickle into distro's, so this workaround might be useful. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- lib/efi_loader/efi_boottime

Re: [U-Boot] [PATCH] dm: core: don't fail to iterate if first one fails to probe

2017-07-19 Thread Rob Clark
On Thu, Jul 13, 2017 at 3:10 PM, Simon Glass <s...@chromium.org> wrote: > Hi Rob, > > On 21 June 2017 at 04:52, Rob Clark <robdcl...@gmail.com> wrote: >> On Wed, Jun 21, 2017 at 6:23 AM, Peter Robinson <pbrobin...@gmail.com> wrote: >>> On Tue, J

Re: [U-Boot] [PATCH 0/5] db410c: updates for grub + gfxterm

2017-07-19 Thread Rob Clark
On Thu, Jul 6, 2017 at 8:02 AM, Mateusz Kulikowski <mateusz.kulikow...@gmail.com> wrote: > Hi Rob, > > On 25.06.2017 01:05, Rob Clark wrote: >> In particular, support for display setup by lk. This introduces a >> simplefb display driver that uses the fra

Re: [U-Boot] [RFC] efi: variable support

2017-07-19 Thread Rob Clark
On Wed, Jul 12, 2017 at 8:57 AM, Alexander Graf <ag...@suse.de> wrote: > > > On 25.06.17 00:29, Rob Clark wrote: >> >> Mapping from EFI variables to grub variables. Still almost as many >> TODOs as lines of code, but just figured I'd send out an early version >

Re: [U-Boot] [PATCH 4/5] efi_loader: gop: fixes for CONFIG_DM_VIDEO without CONFIG_LCD

2017-07-19 Thread Rob Clark
lass wrote: >>>> >>>> Hi, >>>> >>>> On 12 July 2017 at 05:52, Alexander Graf <ag...@suse.de> wrote: >>>>> >>>>> >>>>> On 25.06.17 01:05, Rob Clark wrote: >>>>>> >>>>&g

[U-Boot] [PATCH] video: add config option to skip framebuffer clear

2017-07-04 Thread Rob Clark
The use-case is that the thing that loaded u-boot already put a splash image on screen. And we want to preserve that until grub boot menu takes over. Signed-off-by: Rob Clark <robdcl...@gmail.com> --- drivers/video/Kconfig| 8 drivers/video/cfb_console.c | 2 ++ drivers

<    1   2   3   4   5   6   >