With upcoming changes to 'struct page' this will make the lines
easier to read by using the predefined macros from param.h.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
Differential D58298
LinuxKPI: page.h: use atop() and ptoa() instead of PAGE_SHIFT Authored by bz on Fri, Jul 17, 1:10 PM.
Details
Diff Detail
Event TimelineComment Actions Fine, but this introduces a dependency on sys/param.h wherever these macros are used. Is it ok to include that file into Linux sources in general? Comment Actions % grep -r sys/param.h sys/compat/linuxkpi/common/include/ | wc -l
41
and that includes gfp.h pci.h types.h and kernel.hSo, yes, I believe so :) Also #include <sys/param.h> is already on the file so no change of status quo.
Comment Actions For the discussion, I am still somewhat surprised that so much of the FreeBSD symbols are leaked into linuxkpi headers, Most amusing and dangerous is PAGE_MASK (AFAIR).
Comment Actions .. and a lot of that is "old" stuff .. from the first days (again here 2011). I was contemplating migrating the above out of the header but given things will hopefully change soon I left that for now. What's also scary is all the semi-native code (which most perceive as native driver/code) which relies in parts of the old shortcuts in LinuxKPI... *sigh*.
| ||||||||||||||||||||||||||||||||