Re: [virtio-dev][PATCH V9 2/2] virtio-spi: add the device specification

Harald Mommer <[email protected]>
Newsgroups dev.linux.lists.virtio-dev,dev.linux.lists.virtio-comment
Message-ID <[email protected]>
Hello Haixu,
>
> There are such strange usage scenarios that frame size exceeds 32 
> bits, even 4096 bits. For these strange cases, It's impossible to use 
> only 32 bits bits_per_word_mask to enumerate all the conditions. Seems 
> that a similar situation exists in Linux spi driver also.
>
> Assume a case where the spi controller supports the frame size to be 
> any value from 16 to 64, 32 bits mask can only cover the 16 ~ 32 
> conditions.
>
> Even so, it's not a good idea to expand the bits_per_word_mask, 32 
> bits can cover most of the cases, except for some situations that are 
> not commonly used. Besides, it's hard to determine the bit width to 
> cover all the cases, and expanding will make the logic more 
> complicated. To summarize, I think the following statement is probably 
> proper:
>
> "\field{bits_per_word_mask} is a mask indicating which values of
> bits_per_word are supported. If bit n of \field{bits_per_word_mask} is 
> set, the bits_per_word with value (n+1) is supported. If 
> \field{bits_per_word_mask} is 0, there is no limitation for 
> bits_per_word."
>
> Do you think it is acceptable and appropriate?

Perfect.

Currently in the middle (almost done) of updating my software to draft V10.

Regards
Harald Mommer



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.