mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-09-30 16:40:44 +09:00
Consolidate MAX/MIN definitions
There were several, now there is one (two if you count the lower-case versions). Signed-off-by: Andy Fleming <afleming@freescale.com>
This commit is contained in:
parent
298e476c66
commit
20d04774f4
@ -46,8 +46,6 @@
|
|||||||
# define DFC_DEBUG3(fmt, args...)
|
# define DFC_DEBUG3(fmt, args...)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define MIN(x, y) ((x < y) ? x : y)
|
|
||||||
|
|
||||||
/* These really don't belong here, as they are specific to the NAND Model */
|
/* These really don't belong here, as they are specific to the NAND Model */
|
||||||
static uint8_t scan_ff_pattern[] = { 0xff, 0xff };
|
static uint8_t scan_ff_pattern[] = { 0xff, 0xff };
|
||||||
|
|
||||||
|
@ -46,8 +46,6 @@
|
|||||||
# define DFC_DEBUG3(fmt, args...)
|
# define DFC_DEBUG3(fmt, args...)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define MIN(x, y) ((x < y) ? x : y)
|
|
||||||
|
|
||||||
/* These really don't belong here, as they are specific to the NAND Model */
|
/* These really don't belong here, as they are specific to the NAND Model */
|
||||||
static uint8_t scan_ff_pattern[] = { 0xff, 0xff };
|
static uint8_t scan_ff_pattern[] = { 0xff, 0xff };
|
||||||
|
|
||||||
|
@ -13,10 +13,6 @@
|
|||||||
|
|
||||||
DECLARE_GLOBAL_DATA_PTR;
|
DECLARE_GLOBAL_DATA_PTR;
|
||||||
|
|
||||||
#ifndef MAX
|
|
||||||
#define MAX(a,b) ((a) > (b) ? (a) : (b))
|
|
||||||
#endif
|
|
||||||
|
|
||||||
extern void show_regs __P ((struct pt_regs *));
|
extern void show_regs __P ((struct pt_regs *));
|
||||||
extern int run_command __P ((const char *, int));
|
extern int run_command __P ((const char *, int));
|
||||||
extern char console_buffer[];
|
extern char console_buffer[];
|
||||||
|
@ -23,10 +23,6 @@
|
|||||||
DECLARE_GLOBAL_DATA_PTR;
|
DECLARE_GLOBAL_DATA_PTR;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef MAX
|
|
||||||
#define MAX(a,b) ((a) > (b) ? (a) : (b))
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int valid_elf_image (unsigned long addr);
|
int valid_elf_image (unsigned long addr);
|
||||||
unsigned long load_elf_image (unsigned long addr);
|
unsigned long load_elf_image (unsigned long addr);
|
||||||
|
|
||||||
|
@ -193,8 +193,6 @@ extern int overflowEvent;
|
|||||||
#define LEFT (-1)
|
#define LEFT (-1)
|
||||||
|
|
||||||
/* macros */
|
/* macros */
|
||||||
#define MIN(a, b) ((a) < (b) ? (a) : (b))
|
|
||||||
|
|
||||||
#define IX_ETH_DB_CHECK_PORT_EXISTS(portID) \
|
#define IX_ETH_DB_CHECK_PORT_EXISTS(portID) \
|
||||||
{ \
|
{ \
|
||||||
if ((portID) >= IX_ETH_DB_NUMBER_OF_PORTS) \
|
if ((portID) >= IX_ETH_DB_NUMBER_OF_PORTS) \
|
||||||
|
@ -177,6 +177,9 @@ typedef void (interrupt_handler_t)(void *);
|
|||||||
({ typeof (X) __x = (X), __y = (Y); \
|
({ typeof (X) __x = (X), __y = (Y); \
|
||||||
(__x > __y) ? __x : __y; })
|
(__x > __y) ? __x : __y; })
|
||||||
|
|
||||||
|
#define MIN(x, y) min(x, y)
|
||||||
|
#define MAX(x, y) max(x, y)
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* container_of - cast a member of a structure out to the containing structure
|
* container_of - cast a member of a structure out to the containing structure
|
||||||
|
@ -126,14 +126,6 @@
|
|||||||
})
|
})
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef MIN
|
|
||||||
#define MIN(a,b) ((a) < (b) ? (a) : (b))
|
|
||||||
#endif
|
|
||||||
#ifndef MAX
|
|
||||||
#define MAX(a,b) ((a) > (b) ? (a) : (b))
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Structure member address manipulation macros.
|
* Structure member address manipulation macros.
|
||||||
* These are used by client code (code using the urb_link routines), since
|
* These are used by client code (code using the urb_link routines), since
|
||||||
|
Loading…
Reference in New Issue
Block a user