{drivers,southbridge}: Replace min() with MIN()

This is to remove min/max() from <stdlib.h>.

Change-Id: Ica03d9aec8a81f57709abcac655dfb0ebce3f8c6
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/37818
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Elyes HAOUAS
2019-12-18 21:26:33 +01:00
committed by Patrick Georgi
parent f97c1c9d86
commit 361a935332
16 changed files with 37 additions and 37 deletions

View File

@@ -11,12 +11,12 @@
* GNU General Public License for more details.
*/
#include <commonlib/helpers.h>
#include <commonlib/region.h>
#include <boot_device.h>
#include <fmap.h>
#include <console/console.h>
#include <console/flash.h>
#include <stdlib.h>
#include <types.h>
#define LINE_BUFFER_SIZE 128
@@ -55,7 +55,7 @@ void flashconsole_init(void)
for (i = 0; i < len && offset < size;) {
// Fill the buffer on first iteration
if (i == 0) {
len = min(READ_BUFFER_SIZE, size - offset);
len = MIN(READ_BUFFER_SIZE, size - offset);
if (rdev_readat(&rdev, buffer, offset, len) != len)
return;
}