Skip to content

Commit f9114d3

Browse files
AxelLinhtejun
authored andcommitted
ata: ahci_brcmstb: Fix misuse of IS_ENABLED
While IS_ENABLED() is perfectly fine for CONFIG_* symbols, it is not for other symbols such as __BIG_ENDIAN that is provided directly by the compiler. Switch to use CONFIG_CPU_BIG_ENDIAN instead of __BIG_ENDIAN. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Tejun Heo <tj@kernel.org> Cc: stable@vger.kernel.org
1 parent bb44e15 commit f9114d3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/ata/ahci_brcmstb.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ static inline u32 brcm_sata_readreg(void __iomem *addr)
9292
* Other architectures (e.g., ARM) either do not support big endian, or
9393
* else leave I/O in little endian mode.
9494
*/
95-
if (IS_ENABLED(CONFIG_MIPS) && IS_ENABLED(__BIG_ENDIAN))
95+
if (IS_ENABLED(CONFIG_MIPS) && IS_ENABLED(CONFIG_CPU_BIG_ENDIAN))
9696
return __raw_readl(addr);
9797
else
9898
return readl_relaxed(addr);
@@ -101,7 +101,7 @@ static inline u32 brcm_sata_readreg(void __iomem *addr)
101101
static inline void brcm_sata_writereg(u32 val, void __iomem *addr)
102102
{
103103
/* See brcm_sata_readreg() comments */
104-
if (IS_ENABLED(CONFIG_MIPS) && IS_ENABLED(__BIG_ENDIAN))
104+
if (IS_ENABLED(CONFIG_MIPS) && IS_ENABLED(CONFIG_CPU_BIG_ENDIAN))
105105
__raw_writel(val, addr);
106106
else
107107
writel_relaxed(val, addr);

0 commit comments

Comments
 (0)