On Mon, Jul 04, 2022 at 03:28:07PM +0100, Matthew Wilcox wrote: > On Mon, Jul 04, 2022 at 12:32:20PM +0100, Russell King (Oracle) wrote: > > On Mon, Jul 04, 2022 at 11:48:39AM +0100, Matthew Wilcox wrote: > > > On Mon, Jul 04, 2022 at 05:32:33AM +0100, Russell King (Oracle) wrote: > > > > On Sun, Jul 03, 2022 at 10:54:49PM +0100, Matthew Wilcox wrote: > > > > > On Sun, Jul 03, 2022 at 10:16:45PM +0100, Russell King (Oracle) wrote: > > > > > > On Sun, Jul 03, 2022 at 10:14:41PM +0100, Matthew Wilcox (Oracle) wrote: > > > > > > > This is the number of bits used by a PMD entry, not the order of a PMD. > > > > > > > > > > > > No, it's not the number of bits. A PMD entry doesn't fit in 2 or 3 bits. > > > > > > This is even more confusing. > > > > > > > > > > Well, what is it then? The order of something is PAGE_SIZE << n, and > > > > > that doesn't seem to be what this is. > > > > > > > > Where is it defined that "order" means "PAGE_SIZE << n" ? > > > > > > include/asm-generic/getorder.h: * get_order - Determine the allocation order of a memory size > > > > I really don't care - "order" is something that is a standard term, > > The word "order" has many different uses, just in mathematics alone (to > say nothing of its uses in biology, business, the military, religion, > or signal processing). > > https://en.wikipedia.org/wiki/Order_(mathematics) Right, and no one of those listed there has a claim to exclusive use of the term over any of the others. That even lists the meaning that I'm referring to - "Orders of Magnitude". https://en.wikipedia.org/wiki/Order_of_magnitude "Other orders of magnitude may be calculated using bases other than 10." This usage you don't like is to use ORDER in the kernel to mean "orders of magnitude in base 2" in it's purest form. The calculation here is address = index << PMD_ORDER which is the same as address = index * 2^PMD_ORDER. I have no suggestion for you other than what Mike has put forward, which retains the use of ORDER. If you still object to the use of ORDER, then I'm sorry, but I have no further suggestions. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!