xref: /openbmc/linux/arch/parisc/include/asm/shmparam.h (revision 18afb028)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _ASMPARISC_SHMPARAM_H
3 #define _ASMPARISC_SHMPARAM_H
4 
5 /*
6  * PA-RISC uses virtually indexed & physically tagged (VIPT) caches
7  * which has strict requirements when two pages to the same physical
8  * address are accessed through different mappings. Read the section
9  * "Address Aliasing" in the arch docs for more detail:
10  * PA-RISC 1.1 (page 3-6):
11  * https://parisc.wiki.kernel.org/images-parisc/6/68/Pa11_acd.pdf
12  * PA-RISC 2.0 (page F-5):
13  * https://parisc.wiki.kernel.org/images-parisc/7/73/Parisc2.0.pdf
14  *
15  * For Linux we allow kernel and userspace to map pages on page size
16  * granularity (SHMLBA) but have to ensure that, if two pages are
17  * mapped to the same physical address, the virtual and physical
18  * addresses modulo SHM_COLOUR are identical.
19  */
20 #define SHMLBA	   PAGE_SIZE	/* attach addr a multiple of this */
21 #define SHM_COLOUR 0x00400000	/* shared mappings colouring */
22 
23 #endif /* _ASMPARISC_SHMPARAM_H */
24