On Fri, Jul 30, 2021 at 11:45:37AM -0400, Stefan Berger wrote: > From: Stefan Berger <stef...@linux.ibm.com> > > Move some #defines from ieee1275.c into the common ieee1275.h > header file. Adjust the case used in IHANDLE_INVALID to use > proper ihandle_t. > > Signed-off-by: Stefan Berger <stef...@linux.ibm.com> > --- > grub-core/kern/ieee1275/ieee1275.c | 29 ++++++++++++----------------- > include/grub/ieee1275/ieee1275.h | 3 +++ > 2 files changed, 15 insertions(+), 17 deletions(-) > > diff --git a/grub-core/kern/ieee1275/ieee1275.c > b/grub-core/kern/ieee1275/ieee1275.c > index 86f81a3c4..8fe92274d 100644 > --- a/grub-core/kern/ieee1275/ieee1275.c > +++ b/grub-core/kern/ieee1275/ieee1275.c > @@ -21,11 +21,6 @@ > #include <grub/types.h> > #include <grub/misc.h> > > -#define IEEE1275_PHANDLE_INVALID ((grub_ieee1275_cell_t) -1) > -#define IEEE1275_IHANDLE_INVALID ((grub_ieee1275_cell_t) 0) > -#define IEEE1275_CELL_INVALID ((grub_ieee1275_cell_t) -1) > - > - >
Please drop this empty line too. > int > grub_ieee1275_finddevice (const char *name, grub_ieee1275_phandle_t > *phandlep) > @@ -44,8 +39,7 @@ grub_ieee1275_finddevice (const char *name, > grub_ieee1275_phandle_t *phandlep) > if (IEEE1275_CALL_ENTRY_FN (&args) == -1) > return -1; > *phandlep = args.phandle; > - if (args.phandle == IEEE1275_PHANDLE_INVALID) > - return -1; > + if (args.phandle == GRUB_IEEE1275_PHANDLE_INVALID) return -1; I am not sure why you move "return -1;". You should not... Daniel _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel