29 Jul
2011
29 Jul
'11
8:30 a.m.
At Fri, 29 Jul 2011 10:14:26 +1200, Eliot Blennerhassett wrote:
On 28/07/11 17:43, Takashi Iwai wrote: if ((adapter >= HPI_MAX_ADAPTERS) || (!pa->type)) {
hpi_init_response(&hr->r0, HPI_OBJ_ADAPTER,
HPI_ADAPTER_OPEN,
HPI_ERROR_BAD_ADAPTER_NUMBER);
if (!adapter_present) {
hpi_init_response(&hr->r0, hm->h.object,
hm->h.function, HPI_ERROR_BAD_ADAPTER_NUMBER);
Here you are initializing to different values (from HPI_OBJ_ADAPTER to hm->h.object, etc). Is it intentional?
Yes it is. It is so the error response reflects the parameters of the corresponding message. It makes for better error logging in userspace.
I can redo the patch with better commit log if you like. Adding "Correct error response to reflect message object/function ids"
Yes, please give a matching changelog, then.
thanks,
Takashi