Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 248627
b: refs/heads/master
c: 3e0c2ab
h: refs/heads/master
i:
  248625: 8f41be1
  248623: 0b97740
v: v3
  • Loading branch information
Christoph Lameter authored and Pekka Enberg committed May 21, 2011
1 parent 4a6dc9f commit c688706
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 442b06bcea23a01934d3da7ec5898fa154a6cafb
refs/heads/master: 3e0c2ab67e48f77c2da0a5c826aac397792a214e
6 changes: 4 additions & 2 deletions trunk/include/linux/slub_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,8 @@ static __always_inline int kmalloc_index(size_t size)
if (size <= 4 * 1024) return 12;
/*
* The following is only needed to support architectures with a larger page
* size than 4k.
* size than 4k. We need to support 2 * PAGE_SIZE here. So for a 64k page
* size we would have to go up to 128k.
*/
if (size <= 8 * 1024) return 13;
if (size <= 16 * 1024) return 14;
Expand All @@ -188,7 +189,8 @@ static __always_inline int kmalloc_index(size_t size)
if (size <= 512 * 1024) return 19;
if (size <= 1024 * 1024) return 20;
if (size <= 2 * 1024 * 1024) return 21;
return -1;
BUG();
return -1; /* Will never be reached */

/*
* What we really wanted to do and cannot do because of compiler issues is:
Expand Down

0 comments on commit c688706

Please sign in to comment.