Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 462a2b58 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull ARC fixes from Vineet Gupta:

 - Fallouts/wreckage of Cache Flush optimizations / aliasing dcache
   support

 - Fix for an interesting bug where piped input to grep was getting
   mysteriously clobbered

* tag 'arc-v3.10-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc:
  ARC: lazy dcache flush broke gdb in non-aliasing configs
  ARC: Use enough bits for determining page's cache color
  ARC: Brown paper bag bug in macro for checking cache color
  ARC: copy_(to|from)_user() to honor usermode-access permissions
  ARC: [mm] Prevent stray dcache lines after__sync_icache_dcach()
  ARC: [TB10x] Remove redundant abilis,simple-pinctrl mechanism
parents 4dd9aa89 7bb66f6e
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -37,7 +37,7 @@


	soc100 {
	soc100 {
		uart@FF100000 {
		uart@FF100000 {
			pinctrl-names = "abilis,simple-default";
			pinctrl-names = "default";
			pinctrl-0 = <&pctl_uart0>;
			pinctrl-0 = <&pctl_uart0>;
		};
		};
		ethernet@FE100000 {
		ethernet@FE100000 {
+1 −1
Original line number Original line Diff line number Diff line
@@ -37,7 +37,7 @@


	soc100 {
	soc100 {
		uart@FF100000 {
		uart@FF100000 {
			pinctrl-names = "abilis,simple-default";
			pinctrl-names = "default";
			pinctrl-0 = <&pctl_uart0>;
			pinctrl-0 = <&pctl_uart0>;
		};
		};
		ethernet@FE100000 {
		ethernet@FE100000 {
+2 −4
Original line number Original line Diff line number Diff line
@@ -88,8 +88,7 @@
		};
		};


		uart@FF100000 {
		uart@FF100000 {
			compatible = "snps,dw-apb-uart",
			compatible = "snps,dw-apb-uart";
					"abilis,simple-pinctrl";
			reg = <0xFF100000 0x100>;
			reg = <0xFF100000 0x100>;
			clock-frequency = <166666666>;
			clock-frequency = <166666666>;
			interrupts = <25 1>;
			interrupts = <25 1>;
@@ -184,8 +183,7 @@
			#address-cells = <1>;
			#address-cells = <1>;
			#size-cells = <0>;
			#size-cells = <0>;
			cell-index = <1>;
			cell-index = <1>;
			compatible = "abilis,tb100-spi",
			compatible = "abilis,tb100-spi";
					"abilis,simple-pinctrl";
			num-cs = <2>;
			num-cs = <2>;
			reg = <0xFE011000 0x20>;
			reg = <0xFE011000 0x20>;
			interrupt-parent = <&tb10x_ictl>;
			interrupt-parent = <&tb10x_ictl>;
+4 −2
Original line number Original line Diff line number Diff line
@@ -93,14 +93,16 @@ static inline int cache_is_vipt_aliasing(void)
#endif
#endif
}
}


#define CACHE_COLOR(addr)	(((unsigned long)(addr) >> (PAGE_SHIFT)) & 3)
#define CACHE_COLOR(addr)	(((unsigned long)(addr) >> (PAGE_SHIFT)) & 1)


/*
/*
 * checks if two addresses (after page aligning) index into same cache set
 * checks if two addresses (after page aligning) index into same cache set
 */
 */
#define addr_not_cache_congruent(addr1, addr2)				\
#define addr_not_cache_congruent(addr1, addr2)				\
({									\
	cache_is_vipt_aliasing() ? 					\
	cache_is_vipt_aliasing() ? 					\
		(CACHE_COLOR(addr1) != CACHE_COLOR(addr2)) : 0		\
		(CACHE_COLOR(addr1) != CACHE_COLOR(addr2)) : 0;		\
})


#define copy_to_user_page(vma, page, vaddr, dst, src, len)		\
#define copy_to_user_page(vma, page, vaddr, dst, src, len)		\
do {									\
do {									\
+0 −9
Original line number Original line Diff line number Diff line
@@ -19,13 +19,6 @@
#define clear_page(paddr)		memset((paddr), 0, PAGE_SIZE)
#define clear_page(paddr)		memset((paddr), 0, PAGE_SIZE)
#define copy_page(to, from)		memcpy((to), (from), PAGE_SIZE)
#define copy_page(to, from)		memcpy((to), (from), PAGE_SIZE)


#ifndef CONFIG_ARC_CACHE_VIPT_ALIASING

#define clear_user_page(addr, vaddr, pg)	clear_page(addr)
#define copy_user_page(vto, vfrom, vaddr, pg)	copy_page(vto, vfrom)

#else	/* VIPT aliasing dcache */

struct vm_area_struct;
struct vm_area_struct;
struct page;
struct page;


@@ -35,8 +28,6 @@ void copy_user_highpage(struct page *to, struct page *from,
			unsigned long u_vaddr, struct vm_area_struct *vma);
			unsigned long u_vaddr, struct vm_area_struct *vma);
void clear_user_page(void *to, unsigned long u_vaddr, struct page *page);
void clear_user_page(void *to, unsigned long u_vaddr, struct page *page);


#endif	/* CONFIG_ARC_CACHE_VIPT_ALIASING */

#undef STRICT_MM_TYPECHECKS
#undef STRICT_MM_TYPECHECKS


#ifdef STRICT_MM_TYPECHECKS
#ifdef STRICT_MM_TYPECHECKS
Loading