diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-05-02 01:02:19 +0300 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-05-02 01:02:19 +0300 |
commit | 2dbf3d5c32bf905c2575e5759f2ab6262ec9c6c5 (patch) | |
tree | 87e5db1874023302f19bbd9e5ef37345987e3aa3 /arch/avr32/mach-at32ap/hmatrix.c | |
parent | a25fb8508c1b80dce742dbeaa4d75a1e9f2c5617 (diff) | |
parent | 01e7bc241d4cf8176cfc77ccd13988dc6f0414c4 (diff) | |
download | linux-2dbf3d5c32bf905c2575e5759f2ab6262ec9c6c5.tar.xz |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32
Pull AVR32 removal from Hans-Christian Noren Egtvedt:
"This will remove support for AVR32 architecture from the kernel and
clean away the most obvious architecture related parts. Removing dead
code in drivers is the next step"
Notes from previous discussion about this:
"The AVR32 architecture is not keeping up with the development of the
kernel, and since it shares so much of the drivers with Atmel ARM SoC,
it is starting to hinder these drivers to develop swiftly.
Also, all AVR32 AP7 SoC processors are end of lifed from Atmel (now
Microchip).
Finally, the GCC toolchain is stuck at version 4.2.x, and has not
received any patches since the last release from Atmel;
4.2.4-atmel.1.1.3.avr32linux.1.
When building kernel v4.10, this toolchain is no longer able to
properly link the network stack.
Haavard and I have came to the conclusion that we feel keeping AVR32
on life support offers more obstacles for Atmel ARMs, than it gives
joy to AVR32 users. I also suspect there are very few AVR32 users left
today, if anybody at all"
That discussion was acked by Andy Shevchenko, Boris Brezillon, Nicolas
Ferre, and Haavard Skinnemoen.
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32:
mm: remove AVR32 arch special handling in mm/Kconfig
lib: remove check for AVR32 arch in test_user_copy
lib: remove AVR32 entry in Kconfig.debug compile with frame pointers
scripts: remove AVR32 support from checkstack.pl
docs: remove all references to AVR32 architecture
avr32: remove support for AVR32 architecture
Diffstat (limited to 'arch/avr32/mach-at32ap/hmatrix.c')
-rw-r--r-- | arch/avr32/mach-at32ap/hmatrix.c | 88 |
1 files changed, 0 insertions, 88 deletions
diff --git a/arch/avr32/mach-at32ap/hmatrix.c b/arch/avr32/mach-at32ap/hmatrix.c deleted file mode 100644 index 48f5ede77468..000000000000 --- a/arch/avr32/mach-at32ap/hmatrix.c +++ /dev/null @@ -1,88 +0,0 @@ -/* - * High-Speed Bus Matrix helper functions - * - * Copyright (C) 2008 Atmel Corporation - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - */ -#include <linux/clk.h> -#include <linux/io.h> - -#include <mach/chip.h> -#include <mach/hmatrix.h> - -static inline void __hmatrix_write_reg(unsigned long offset, u32 value) -{ - __raw_writel(value, (void __iomem __force *)(HMATRIX_BASE + offset)); -} - -static inline u32 __hmatrix_read_reg(unsigned long offset) -{ - return __raw_readl((void __iomem __force *)(HMATRIX_BASE + offset)); -} - -/** - * hmatrix_write_reg - write HMATRIX configuration register - * @offset: register offset - * @value: value to be written to the register at @offset - */ -void hmatrix_write_reg(unsigned long offset, u32 value) -{ - clk_enable(&at32_hmatrix_clk); - __hmatrix_write_reg(offset, value); - __hmatrix_read_reg(offset); - clk_disable(&at32_hmatrix_clk); -} - -/** - * hmatrix_read_reg - read HMATRIX configuration register - * @offset: register offset - * - * Returns the value of the register at @offset. - */ -u32 hmatrix_read_reg(unsigned long offset) -{ - u32 value; - - clk_enable(&at32_hmatrix_clk); - value = __hmatrix_read_reg(offset); - clk_disable(&at32_hmatrix_clk); - - return value; -} - -/** - * hmatrix_sfr_set_bits - set bits in a slave's Special Function Register - * @slave_id: operate on the SFR belonging to this slave - * @mask: mask of bits to be set in the SFR - */ -void hmatrix_sfr_set_bits(unsigned int slave_id, u32 mask) -{ - u32 value; - - clk_enable(&at32_hmatrix_clk); - value = __hmatrix_read_reg(HMATRIX_SFR(slave_id)); - value |= mask; - __hmatrix_write_reg(HMATRIX_SFR(slave_id), value); - __hmatrix_read_reg(HMATRIX_SFR(slave_id)); - clk_disable(&at32_hmatrix_clk); -} - -/** - * hmatrix_sfr_set_bits - clear bits in a slave's Special Function Register - * @slave_id: operate on the SFR belonging to this slave - * @mask: mask of bits to be cleared in the SFR - */ -void hmatrix_sfr_clear_bits(unsigned int slave_id, u32 mask) -{ - u32 value; - - clk_enable(&at32_hmatrix_clk); - value = __hmatrix_read_reg(HMATRIX_SFR(slave_id)); - value &= ~mask; - __hmatrix_write_reg(HMATRIX_SFR(slave_id), value); - __hmatrix_read_reg(HMATRIX_SFR(slave_id)); - clk_disable(&at32_hmatrix_clk); -} |