Rework ptep_set_access_flags and fix sun4c

Some changes done a while ago to avoid pounding on ptep_set_access_flags and
update_mmu_cache in some race situations break sun4c which requires
update_mmu_cache() to always be called on minor faults.

This patch reworks ptep_set_access_flags() semantics, implementations and
callers so that it's now responsible for returning whether an update is
necessary or not (basically whether the PTE actually changed).  This allow
fixing the sparc implementation to always return 1 on sun4c.

[[email protected]: fixes, cleanups]
Signed-off-by: Benjamin Herrenschmidt <[email protected]>
Cc: Hugh Dickins <[email protected]>
Cc: David Miller <[email protected]>
Cc: Mark Fortescue <[email protected]>
Acked-by: William Lee Irwin III <[email protected]>
Cc: "Luck, Tony" <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
11 files changed