aboutsummaryrefslogtreecommitdiffstats
path: root/mm/slob.c
diff options
context:
space:
mode:
authorOlof Johansson <olof@lixom.net>2012-10-19 15:40:18 -0700
committerOlof Johansson <olof@lixom.net>2012-10-19 15:40:18 -0700
commit068a565afad3ae818cc0d5495479c4abccc7762c (patch)
tree4243dbfa3250cc4da757b3fbc03462267e4e2426 /mm/slob.c
parentb55a7a5fbf09ea59777c3b41b6f5cb1ae81aa2bb (diff)
parent5276b6877efb8a180e254a06d7497f802f6f9755 (diff)
downloadkernel_goldelico_gta04-068a565afad3ae818cc0d5495479c4abccc7762c.zip
kernel_goldelico_gta04-068a565afad3ae818cc0d5495479c4abccc7762c.tar.gz
kernel_goldelico_gta04-068a565afad3ae818cc0d5495479c4abccc7762c.tar.bz2
Merge branch 'testing/driver-warnings' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc into fixes
A collection of warning fixes on non-ARM code from Arnd Bergmann: * 'testing/driver-warnings' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: ARM: s3c: mark s3c2440_clk_add as __init_refok spi/s3c64xx: use correct dma_transfer_direction type pcmcia: sharpsl: don't discard sharpsl_pcmcia_ops USB: EHCI: mark ehci_orion_conf_mbus_windows __devinit mm/slob: use min_t() to compare ARCH_SLAB_MINALIGN SCSI: ARM: make fas216_dumpinfo function conditional SCSI: ARM: ncr5380/oak uses no interrupts
Diffstat (limited to 'mm/slob.c')
-rw-r--r--mm/slob.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/mm/slob.c b/mm/slob.c
index a08e468..1e921c5 100644
--- a/mm/slob.c
+++ b/mm/slob.c
@@ -429,7 +429,7 @@ static __always_inline void *
__do_kmalloc_node(size_t size, gfp_t gfp, int node, unsigned long caller)
{
unsigned int *m;
- int align = max(ARCH_KMALLOC_MINALIGN, ARCH_SLAB_MINALIGN);
+ int align = max_t(size_t, ARCH_KMALLOC_MINALIGN, ARCH_SLAB_MINALIGN);
void *ret;
gfp &= gfp_allowed_mask;
@@ -502,7 +502,7 @@ void kfree(const void *block)
sp = virt_to_page(block);
if (PageSlab(sp)) {
- int align = max(ARCH_KMALLOC_MINALIGN, ARCH_SLAB_MINALIGN);
+ int align = max_t(size_t, ARCH_KMALLOC_MINALIGN, ARCH_SLAB_MINALIGN);
unsigned int *m = (unsigned int *)(block - align);
slob_free(m, *m + align);
} else
@@ -521,7 +521,7 @@ size_t ksize(const void *block)
sp = virt_to_page(block);
if (PageSlab(sp)) {
- int align = max(ARCH_KMALLOC_MINALIGN, ARCH_SLAB_MINALIGN);
+ int align = max_t(size_t, ARCH_KMALLOC_MINALIGN, ARCH_SLAB_MINALIGN);
unsigned int *m = (unsigned int *)(block - align);
return SLOB_UNITS(*m) * SLOB_UNIT;
} else