On Thu, 12 Dec 2019 19:20:07 +0100 Pierre Morel <pmorel@xxxxxxxxxxxxx> wrote: > On 2019-12-12 15:10, Pierre Morel wrote: > > > > > > On 2019-12-12 13:26, Cornelia Huck wrote: > >> On Wed, 11 Dec 2019 16:46:09 +0100 > >> Pierre Morel <pmorel@xxxxxxxxxxxxx> wrote: > >>> + > >>> + senseid.cu_type = buffer[2] | (buffer[1] << 8); > >> > >> This still looks odd; why not have the ccw fill out the senseid > >> structure directly? > > > > Oh sorry, you already said and I forgot to modify this. > > thanks > > hum, sorry, I forgot, the sense structure is not padded so I need this. Very confused; I see padding in the senseid structure? (And what does padding have to do with it?) Also, you only copy the cu type... it would really be much better if you looked at the whole structure you got back from the hypervisor; that would also allow you to do some more sanity checks etc. If you really can't pass in a senseid structure directly, just copy everything you got?