Re: [PATCH 5/5] ASoC: mediatek: mt8188-mt6359: Use bitfield macros for registers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/06/2023 11:57, AngeloGioacchino Del Regno wrote:
-    int test_done_1, test_done_2;
+    u8 test_done_1, test_done_2;
      int cycle_1, cycle_2;

Shouldn't be unsigned too ?

I'm wondering if it would be better (probably in another patch) to change the data type of the other variables too, to match their use-case. (maybe it's already the case, I'm just wondering)


In theory, yes, cycle_1 and 2 should be unsigned, but the signedness of this
variable is getting used in the calibration logic later, as in the for loop
they are both being reinitialized to -1 ... so I couldn't just switch 'em to
unsigned.

Understood, thanks for your explanation.

--
Regards,
Alexandre




[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux