Skip to content

Commit ea66589

Browse files
committed
fbdev: c2p: Use BUILD_BUG() instead of custom solution
Replace the call to the custom non-existing function by a standard BUILD_BUG() invocation. Suggested-by: Masahiro Yamada <[email protected]> Signed-off-by: Geert Uytterhoeven <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 435cb3e commit ea66589

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

drivers/video/fbdev/c2p_core.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212
* for more details.
1313
*/
1414

15+
#include <linux/build_bug.h>
16+
1517

1618
/*
1719
* Basic transpose step
@@ -27,8 +29,6 @@ static inline void _transp(u32 d[], unsigned int i1, unsigned int i2,
2729
}
2830

2931

30-
extern void c2p_unsupported(void);
31-
3232
static __always_inline u32 get_mask(unsigned int n)
3333
{
3434
switch (n) {
@@ -48,7 +48,7 @@ static __always_inline u32 get_mask(unsigned int n)
4848
return 0x0000ffff;
4949
}
5050

51-
c2p_unsupported();
51+
BUILD_BUG();
5252
return 0;
5353
}
5454

@@ -91,7 +91,7 @@ static __always_inline void transp8(u32 d[], unsigned int n, unsigned int m)
9191
return;
9292
}
9393

94-
c2p_unsupported();
94+
BUILD_BUG();
9595
}
9696

9797

@@ -118,7 +118,7 @@ static __always_inline void transp4(u32 d[], unsigned int n, unsigned int m)
118118
return;
119119
}
120120

121-
c2p_unsupported();
121+
BUILD_BUG();
122122
}
123123

124124

@@ -138,7 +138,7 @@ static __always_inline void transp4x(u32 d[], unsigned int n, unsigned int m)
138138
return;
139139
}
140140

141-
c2p_unsupported();
141+
BUILD_BUG();
142142
}
143143

144144

0 commit comments

Comments
 (0)