From: Michael Brown Date: Fri, 20 May 2016 12:05:39 +0000 (+0100) Subject: [settings] Extend numerical setting tags to "unsigned long" X-Git-Tag: v1.20.1~442 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=56c0147deb4c36bf28fa4ac7f3cefdad726346e4;p=thirdparty%2Fipxe.git [settings] Extend numerical setting tags to "unsigned long" Signed-off-by: Michael Brown --- diff --git a/src/core/memmap_settings.c b/src/core/memmap_settings.c index fab3e5f3a..1098bd756 100644 --- a/src/core/memmap_settings.c +++ b/src/core/memmap_settings.c @@ -145,7 +145,7 @@ static int memmap_settings_fetch ( struct settings *settings, unsigned int i; unsigned int count; - DBGC ( settings, "MEMMAP start %d count %d %s%s%s%s scale %d\n", + DBGC ( settings, "MEMMAP start %ld count %ld %s%s%s%s scale %ld\n", MEMMAP_START ( setting->tag ), MEMMAP_COUNT ( setting->tag ), ( MEMMAP_INCLUDE_START ( setting->tag ) ? "start" : "" ), ( ( MEMMAP_INCLUDE_START ( setting->tag ) && diff --git a/src/core/settings.c b/src/core/settings.c index f6f62d226..757555781 100644 --- a/src/core/settings.c +++ b/src/core/settings.c @@ -1474,9 +1474,9 @@ struct setting * find_setting ( const char *name ) { * @v name Name * @ret tag Tag number, or 0 if not a valid number */ -static unsigned int parse_setting_tag ( const char *name ) { +static unsigned long parse_setting_tag ( const char *name ) { char *tmp = ( ( char * ) name ); - unsigned int tag = 0; + unsigned long tag = 0; while ( 1 ) { tag = ( ( tag << 8 ) | strtoul ( tmp, &tmp, 0 ) ); diff --git a/src/include/ipxe/settings.h b/src/include/ipxe/settings.h index b44794af2..6534c25b6 100644 --- a/src/include/ipxe/settings.h +++ b/src/include/ipxe/settings.h @@ -40,7 +40,7 @@ struct setting { * (such as a DHCP option number, or an SMBIOS structure and * field number). */ - unsigned int tag; + unsigned long tag; /** Setting scope (or NULL) * * For historic reasons, a NULL scope with a non-zero tag