Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1534720
| From | Anatolij Gustschin <agust@denx.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v4 1/3] lib: add bitrev8x4() |
| Date | 2016-12-02 09:00 +0100 |
| Message-ID | <sJQVh-HL-9@gated-at.bofh.it> (permalink) |
| References | <sJD1U-70r-15@gated-at.bofh.it> <sJD1U-70r-13@gated-at.bofh.it> <sJIkW-3mt-3@gated-at.bofh.it> <sJJAl-4m3-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi Joshua,
On Thu, 1 Dec 2016 16:04:09 -0800
Joshua Clayton stillcompiling@gmail.com wrote:
...
>>> +static __always_inline __attribute_const__ u32 __arch_bitrev8x4(u32 x)
>>> +{
>>> + __asm__ ("rbit %0, %1; rev %0, %0" : "=r" (x) : "r" (x));
>> return x;
>Oops thats a little embarrassing;
>I'll add a return.
>>> +}
>> otherwise you get
>>
>> In function '__arch_bitrev8x4':
>> warning: no return statement in function returning non-void [-Wreturn-type]
>>
>
>I wonder why I do not see this warning when compiling. The inlining, maybe?
do you have CONFIG_HAVE_ARCH_BITREVERSE=y in your .config?
Probably not optimized code is used, otherwise you will send wrong
data to FPGA (due to wrong return values from __arch_bitrev8x4).
Anatolij
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH v4 1/3] lib: add bitrev8x4() Joshua Clayton <stillcompiling@gmail.com> - 2016-12-01 18:10 +0100
Re: [PATCH v4 1/3] lib: add bitrev8x4() Anatolij Gustschin <agust@denx.de> - 2016-12-01 23:50 +0100
Re: [PATCH v4 1/3] lib: add bitrev8x4() Joshua Clayton <stillcompiling@gmail.com> - 2016-12-02 01:10 +0100
Re: [PATCH v4 1/3] lib: add bitrev8x4() Anatolij Gustschin <agust@denx.de> - 2016-12-02 09:00 +0100
csiph-web