Kirill A. Shutemov 23baf831a3 mm, treewide: redefine MAX_ORDER sanely
MAX_ORDER currently defined as number of orders page allocator supports:
user can ask buddy allocator for page order between 0 and MAX_ORDER-1.

This definition is counter-intuitive and lead to number of bugs all over
the kernel.

Change the definition of MAX_ORDER to be inclusive: the range of orders
user can ask from buddy allocator is 0..MAX_ORDER now.

[kirill@shutemov.name: fix min() warning]
  Link: https://lkml.kernel.org/r/20230315153800.32wib3n5rickolvh@box
[akpm@linux-foundation.org: fix another min_t warning]
[kirill@shutemov.name: fixups per Zi Yan]
  Link: https://lkml.kernel.org/r/20230316232144.b7ic4cif4kjiabws@box.shutemov.name
[akpm@linux-foundation.org: fix underlining in docs]
  Link: https://lore.kernel.org/oe-kbuild-all/202303191025.VRCTk6mP-lkp@intel.com/
Link: https://lkml.kernel.org/r/20230315113133.11326-11-kirill.shutemov@linux.intel.com
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Reviewed-by: Michael Ellerman <mpe@ellerman.id.au>	[powerpc]
Cc: "Kirill A. Shutemov" <kirill@shutemov.name>
Cc: Zi Yan <ziy@nvidia.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2023-04-05 19:42:46 -07:00
..
2023-03-24 13:45:58 -07:00
2023-03-16 16:54:38 +09:00
2023-02-25 09:19:23 -08:00
2023-02-25 09:19:23 -08:00
2023-02-24 17:18:54 -08:00
2023-02-24 12:58:55 -08:00
2023-03-24 15:38:13 -07:00
2023-02-24 12:58:55 -08:00
2023-03-09 10:17:23 -08:00
2023-02-24 12:58:55 -08:00
2023-02-24 12:58:55 -08:00
2023-02-24 12:58:55 -08:00
2023-02-28 16:05:01 -08:00
2023-02-21 12:13:58 -08:00
2023-02-24 15:11:03 -08:00
2023-02-27 10:04:49 -08:00
2023-02-24 12:58:55 -08:00
2023-02-23 15:09:31 -08:00
2023-02-25 11:00:06 -08:00
2023-02-27 09:47:26 -08:00
2023-02-25 11:48:02 -08:00
2023-02-24 13:40:13 -08:00
2023-02-24 12:58:55 -08:00
2023-02-27 10:04:49 -08:00
2023-02-27 10:04:49 -08:00
2023-02-20 12:26:35 +01:00
2023-03-02 09:21:25 -08:00
2023-02-27 10:04:49 -08:00
2023-02-26 12:10:28 -08:00
2023-03-03 09:15:50 -08:00
2023-03-03 14:41:50 -08:00
2023-03-24 08:27:13 -07:00
2023-03-01 09:44:22 -08:00
2023-02-24 17:29:52 -08:00
2023-03-02 09:25:38 -08:00
2023-03-09 10:06:28 +01:00
2023-03-24 17:11:27 +01:00
2023-03-24 09:44:43 -07:00
2023-03-02 11:12:01 -08:00
2023-03-17 10:45:49 -07:00
2023-02-26 11:53:25 -08:00