From: "Valo, Kalle" <kvalo@qca.qualcomm.com> To: Erik Stromdahl <erik.stromdahl@gmail.com> Cc: "michal.kazior@tieto.com" <michal.kazior@tieto.com>, linux-wireless <linux-wireless@vger.kernel.org>, "ath10k@lists.infradead.org" <ath10k@lists.infradead.org> Subject: Re: [RFC 02/12] ath10k: htc: rx trailer lookahead support Date: Wed, 16 Nov 2016 13:53:00 +0000 [thread overview] Message-ID: <87eg2bo7k7.fsf@kamboji.qca.qualcomm.com> (raw) In-Reply-To: <ac58b3f6-4432-b0b6-8b50-c733f898eded@gmail.com> (Erik Stromdahl's message of "Tue, 15 Nov 2016 18:31:15 +0100") Erik Stromdahl <erik.stromdahl@gmail.com> writes: > On 11/15/2016 10:57 AM, Michal Kazior wrote: >> On 14 November 2016 at 17:33, Erik Stromdahl <erik.stromdahl@gmail.com> = wrote: >>> The RX trailer parsing is now capable of parsing lookahead reports. >>> This is needed by SDIO/mbox. >>=20 >> It'd be useful to know what exactly lookahead will be used for. What >> payload does it carry. >>=20 > It carries the 4 first bytes of the next RX message, i.e. the first 4 > bytes of an HTC header. > > It is used by the sdio interrupt handler to know if the next packet is a > part of an RX bundle, which endpoint it belongs to and how long it is > (so we know how many bytes to allocate). Please add that to the commit log, it's useful information. Or maybe a code comment would be better? >>> +static int >>> +ath10k_htc_process_lookahead(struct ath10k_htc *htc, >>> + const struct ath10k_htc_lookahead_report *= report, >>> + int len, >>> + enum ath10k_htc_ep_id eid, >>> + u32 *next_lk_ahds, >>=20 >> next_lk_ahds should be u8 or void. From what I understand by glancing >> through the code it is an agnostic buffer that carries payload which >> is later interpreted either as eid or htc header, right? void is >> probably most suitable in this case for passing around and u8 for >> inline-based storage. >>=20 > Sounds reasonable, I'll change to void pointer. > >> I'd also avoid silly abbreviations. Probably "lookahead" alone is enough= . >>=20 > Ok, this abbreviation was actually taken from the ath6kl code. I think > the intention was to reduce line lengths. Most likely that comes from the staging ath6kl driver which again is a fork of the Atheros internal driver. I agree with Michal, better to avoid silly abbreviations as much as possible. Readability is most important. --=20 Kalle Valo=
WARNING: multiple messages have this Message-ID (diff)
From: "Valo, Kalle" <kvalo@qca.qualcomm.com> To: Erik Stromdahl <erik.stromdahl@gmail.com> Cc: linux-wireless <linux-wireless@vger.kernel.org>, "michal.kazior@tieto.com" <michal.kazior@tieto.com>, "ath10k@lists.infradead.org" <ath10k@lists.infradead.org> Subject: Re: [RFC 02/12] ath10k: htc: rx trailer lookahead support Date: Wed, 16 Nov 2016 13:53:00 +0000 [thread overview] Message-ID: <87eg2bo7k7.fsf@kamboji.qca.qualcomm.com> (raw) In-Reply-To: <ac58b3f6-4432-b0b6-8b50-c733f898eded@gmail.com> (Erik Stromdahl's message of "Tue, 15 Nov 2016 18:31:15 +0100") Erik Stromdahl <erik.stromdahl@gmail.com> writes: > On 11/15/2016 10:57 AM, Michal Kazior wrote: >> On 14 November 2016 at 17:33, Erik Stromdahl <erik.stromdahl@gmail.com> wrote: >>> The RX trailer parsing is now capable of parsing lookahead reports. >>> This is needed by SDIO/mbox. >> >> It'd be useful to know what exactly lookahead will be used for. What >> payload does it carry. >> > It carries the 4 first bytes of the next RX message, i.e. the first 4 > bytes of an HTC header. > > It is used by the sdio interrupt handler to know if the next packet is a > part of an RX bundle, which endpoint it belongs to and how long it is > (so we know how many bytes to allocate). Please add that to the commit log, it's useful information. Or maybe a code comment would be better? >>> +static int >>> +ath10k_htc_process_lookahead(struct ath10k_htc *htc, >>> + const struct ath10k_htc_lookahead_report *report, >>> + int len, >>> + enum ath10k_htc_ep_id eid, >>> + u32 *next_lk_ahds, >> >> next_lk_ahds should be u8 or void. From what I understand by glancing >> through the code it is an agnostic buffer that carries payload which >> is later interpreted either as eid or htc header, right? void is >> probably most suitable in this case for passing around and u8 for >> inline-based storage. >> > Sounds reasonable, I'll change to void pointer. > >> I'd also avoid silly abbreviations. Probably "lookahead" alone is enough. >> > Ok, this abbreviation was actually taken from the ath6kl code. I think > the intention was to reduce line lengths. Most likely that comes from the staging ath6kl driver which again is a fork of the Atheros internal driver. I agree with Michal, better to avoid silly abbreviations as much as possible. Readability is most important. -- Kalle Valo _______________________________________________ ath10k mailing list ath10k@lists.infradead.org http://lists.infradead.org/mailman/listinfo/ath10k
next prev parent reply other threads:[~2016-11-16 13:53 UTC|newest] Thread overview: 62+ messages / expand[flat|nested] mbox.gz Atom feed top 2016-11-14 16:33 [RFC 00/12] ath10k sdio support Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 01/12] ath10k: htc: made static function public Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 02/12] ath10k: htc: rx trailer lookahead support Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 9:57 ` Michal Kazior 2016-11-15 9:57 ` Michal Kazior 2016-11-15 17:31 ` Erik Stromdahl 2016-11-15 17:31 ` Erik Stromdahl 2016-11-16 13:53 ` Valo, Kalle [this message] 2016-11-16 13:53 ` Valo, Kalle 2016-11-14 16:33 ` [RFC 03/12] ath10k: htc: Changed order of wait target and ep connect Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 10:13 ` Michal Kazior 2016-11-15 10:13 ` Michal Kazior 2016-11-15 17:07 ` Erik Stromdahl 2016-11-15 17:07 ` Erik Stromdahl 2016-11-16 14:29 ` Michal Kazior 2016-11-16 14:29 ` Michal Kazior 2016-11-14 16:33 ` [RFC 04/12] ath10k: htc: refactorization Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 10:19 ` Michal Kazior 2016-11-15 10:19 ` Michal Kazior 2016-11-17 16:32 ` Erik Stromdahl 2016-11-17 16:32 ` Erik Stromdahl 2016-11-18 14:49 ` Michal Kazior 2016-11-18 14:49 ` Michal Kazior 2016-11-14 16:33 ` [RFC 05/12] ath10k: htc: Added ATH10K_HTC_FLAG_BUNDLE_LSB Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 10:25 ` Michal Kazior 2016-11-15 10:25 ` Michal Kazior 2016-11-15 10:46 ` Valo, Kalle 2016-11-15 10:46 ` Valo, Kalle 2016-11-14 16:33 ` [RFC 06/12] ath10k: bmi: Added SOC reg read/write functions Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 10:28 ` Michal Kazior 2016-11-15 10:28 ` Michal Kazior 2016-11-15 17:11 ` Erik Stromdahl 2016-11-15 17:11 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 07/12] ath10k: Added SDIO dbg masks Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 08/12] ath10k: Added ATH10K_BUS_SDIO enum Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 09/12] ath10k: Mailbox address definitions Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 10:31 ` Michal Kazior 2016-11-15 10:31 ` Michal Kazior 2016-11-15 10:48 ` Valo, Kalle 2016-11-15 10:48 ` Valo, Kalle 2016-11-14 16:33 ` [RFC 10/12] ath10k: Added QCA65XX hw definition Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-15 10:34 ` Michal Kazior 2016-11-15 10:34 ` Michal Kazior 2016-11-15 10:54 ` Valo, Kalle 2016-11-15 10:54 ` Valo, Kalle 2016-11-15 18:34 ` Erik Stromdahl 2016-11-15 18:34 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 11/12] ath10k: Added more host_interest members Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl 2016-11-14 16:33 ` [RFC 12/12] ath10k: Added sdio support Erik Stromdahl 2016-11-14 16:33 ` Erik Stromdahl
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=87eg2bo7k7.fsf@kamboji.qca.qualcomm.com \ --to=kvalo@qca.qualcomm.com \ --cc=ath10k@lists.infradead.org \ --cc=erik.stromdahl@gmail.com \ --cc=linux-wireless@vger.kernel.org \ --cc=michal.kazior@tieto.com \ /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: linkBe 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.