Commit deebe5f6 authored by Thomas Zimmermann's avatar Thomas Zimmermann Committed by Michael Ellerman
Browse files

powerpc/fb: Call internal __phys_mem_access_prot() in fbdev code



Call __phys_mem_access_prot() from the fbdev mmap helper
pgprot_framebuffer(). Allows to avoid the file argument of NULL.

Signed-off-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20230922080636.26762-6-tzimmermann@suse.de
parent 1f92a844
Loading
Loading
Loading
Loading
+1 −6
Original line number Diff line number Diff line
@@ -8,12 +8,7 @@ static inline pgprot_t pgprot_framebuffer(pgprot_t prot,
					  unsigned long vm_start, unsigned long vm_end,
					  unsigned long offset)
{
	/*
	 * PowerPC's implementation of phys_mem_access_prot() does
	 * not use the file argument. Set it to NULL in preparation
	 * of later updates to the interface.
	 */
	return phys_mem_access_prot(NULL, PHYS_PFN(offset), vm_end - vm_start, prot);
	return __phys_mem_access_prot(PHYS_PFN(offset), vm_end - vm_start, prot);
}
#define pgprot_framebuffer pgprot_framebuffer