From: Raja Mani <rmani@qca.qualcomm.com>
To: Kalle Valo <kvalo@qca.qualcomm.com>
Cc: <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH 1/7] ath6kl: Add wmi functions to add/delete wow patterns
Date: Mon, 31 Oct 2011 15:22:30 +0530 [thread overview]
Message-ID: <4EAE6FDE.4060105@qca.qualcomm.com> (raw)
In-Reply-To: <4EAA9BE2.7050808@qca.qualcomm.com>
On Friday 28 October 2011 05:41 PM, Kalle Valo wrote:
> On 10/25/2011 01:37 PM, rmani@qca.qualcomm.com wrote:
>> From: Raja Mani<rmani@qca.qualcomm.com>
>>
>> Signed-off-by: Raja Mani<rmani@qca.qualcomm.com>
>
> Try to avoid empty commit logs. You could just say that these commands
> will be used by the following patch if nothing else.
>
>> +int ath6kl_wmi_add_wow_pattern_cmd(struct wmi *wmi,
>> + struct wmi_add_wow_pattern_cmd *add_wow_cmd,
>> + u8 *pattern, u8 *mask)
>> +{
>
> Don't use a struct as the parameter, instead add individual parameters.
> So something like this:
>
> int ath6kl_wmi_add_wow_pattern_cmd(struct wmi *wmi,
> u8 id, u8 size, 8 offset,
> u8 *pattern, u8 *mask)
>
> This is easier for the caller and you get to handle the endian in the
> callee which simplifies the code.
Agree.. I'll take care in V2.
>
>> + size = sizeof(*cmd) +
>> + ((2 * add_wow_cmd->filter_size) * sizeof(u8));
>
> This can fit into line. And sizeof(u8) really doesn't make any sense.
>
> And is this correct? The struct is defined like this:
>
> +struct wmi_add_wow_pattern_cmd {
> + u8 filter_list_id;
> + u8 filter_size;
> + u8 filter_offset;
> + u8 filter[1];
> +} __packed;
>
> So there's one extra byte for the filter and above you include also that
> byte. But if the sctruct is defined like this the extra byte is not
> included:
>
> +struct wmi_add_wow_pattern_cmd {
> + u8 filter_list_id;
> + u8 filter_size;
> + u8 filter_offset;
> + u8 filter[0];
> +} __packed;
>
Good catch.. I'll correct it.
>> +int ath6kl_wmi_del_wow_pattern_cmd(struct wmi *wmi,
>> + struct wmi_del_wow_pattern_cmd *del_wow_cmd)
>
> Same here as earlier, don't use the struct as a parameter.
Okay..
>
> Kalle
next prev parent reply other threads:[~2011-10-31 9:52 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-25 10:37 [PATCH 0/7] ath6kl: Add WOW support rmani
2011-10-25 10:37 ` [PATCH 1/7] ath6kl: Add wmi functions to add/delete wow patterns rmani
2011-10-28 12:11 ` Kalle Valo
2011-10-31 9:52 ` Raja Mani [this message]
2011-10-25 10:37 ` [PATCH 2/7] ath6kl: Add wmi functions to configure wow mode and host sleep mode rmani
2011-10-28 12:19 ` Kalle Valo
2011-10-31 9:53 ` Raja Mani
2011-10-31 13:10 ` Kalle Valo
2011-10-25 10:37 ` [PATCH 3/7] ath6kl: Introduce new variable to track wow state machine rmani
2011-10-25 10:37 ` [PATCH 4/7] ath6kl: Add new functions to handle wow suspend/resume operations rmani
2011-10-28 12:31 ` Kalle Valo
2011-10-31 9:53 ` Raja Mani
2011-10-25 10:37 ` [PATCH 5/7] ath6kl: Invoke wow suspend/resume calls during PM operations rmani
2011-10-28 13:15 ` Kalle Valo
2011-10-31 9:54 ` Raja Mani
2011-10-31 13:16 ` Kalle Valo
2011-10-28 13:21 ` Kalle Valo
2011-10-31 9:54 ` Raja Mani
2011-10-31 13:29 ` Kalle Valo
2011-10-25 10:37 ` [PATCH 6/7] ath6kl: Perform WOW resume in RX path in case of SDIO IRQ wakeup rmani
2011-10-28 13:18 ` Kalle Valo
2011-10-31 9:55 ` Raja Mani
2011-10-31 13:03 ` Kalle Valo
2011-10-25 10:37 ` [PATCH 7/7] ath6kl: Expose ath6kl wow capabilities to cfg layer rmani
2011-10-28 11:58 ` [PATCH 0/7] ath6kl: Add WOW support Kalle Valo
2011-10-31 9:55 ` Raja Mani
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4EAE6FDE.4060105@qca.qualcomm.com \
--to=rmani@qca.qualcomm.com \
--cc=kvalo@qca.qualcomm.com \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.