All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jes Sorensen <jes.sorensen@gmail.com>
To: Vaishali Thakkar <vthakkar1994@gmail.com>
Cc: Arnd Bergmann <arnd@arndb.de>, outreachy-kernel@googlegroups.com
Subject: Re: [Outreachy kernel] [PATCH] Staging: rtl8188eu: Use put_unaligned_le16
Date: Wed, 18 Feb 2015 17:31:09 -0500	[thread overview]
Message-ID: <54E512AD.4040303@gmail.com> (raw)
In-Reply-To: <CAK-LDbJAJGtD=4tw7D8v0AT-RBiX-Hdn0drK01UqfnhNdgbt8A@mail.gmail.com>

On 02/18/15 13:08, Vaishali Thakkar wrote:
> On Wed, Feb 18, 2015 at 10:40 PM, Jes Sorensen <jes.sorensen@gmail.com> wrote:
>> On 02/18/15 05:50, Arnd Bergmann wrote:
>>> On Wednesday 18 February 2015 07:02:34 Vaishali Thakkar wrote:
>>>> On Wed, Feb 18, 2015 at 12:42 AM, Jes Sorensen <jes.sorensen@gmail.com> wrote:
>>>>> On 02/17/15 05:11, Vaishali Thakkar wrote:
>>>>> Your use of put_unaligned_le16() if good, the main issue is the above
>>>>> assignment as you mention. Since you got rid of the tim_bitmap_le =
>>>>> portion, the *dst_ie++ = is going to assigning random garbage since
>>>>> tim_bitmap_le is not set.
>>>>>
>>>>> One way to solve the problem would be to make that line say
>>>>>
>>>>>                 if (tim_ielen == 4) {
>>>>> -                       *dst_ie++ = *(u8 *)&tim_bitmap_le;
>>>>> +                       *dst_ie++ = pstapriv->tim_bitmap & 0xff;
>>>>>                 } else if (tim_ielen == 5) {
>>>>> -                       memcpy(dst_ie, &tim_bitmap_le, 2);
>>>>> +                       put_unaligned_le16(pstapriv->tim_bitmap, dst_ie);
>>>>>
>>>>> and hopefully eliminate the tim_bitmap_le variable completely.
>>>>
>>>> Yes. This makes sense. And as there is only one use of tim_bitmap_le
>>>> variable this will eliminate it completely. Should I go for v2 now, with this
>>>> change?? I have one more such case in rtl8723au driver also. I think now
>>>> I can go for it also.
>>>
>>> Yes, please submit the change for both drivers as separate patches.
>>
>> As Arnd says, please use two patches. The reason is that the two drivers
>> are completely independent and also have separate maintainers (me owning
>> rtl8723au fwiw).
> 
> Sorry I didn't get you.
> 
> Yes, I know both drivers are independent. So, I will send 2 different patches.
> Here, I sent only one patch for rtl8188eu. I didn't send any patch for
> rtl8723au.
> I am working on it and supposed to send it now.

Sorry if I wasn't clear here.

The key is to make the changes in two commits. In general you can post
them as part of a multi-commit patch set if you are fixing something in
a large number of places, or changing an API etc. For more independent
changes like these, posting them individually is preferred.

I hope this makes more sense.

Jes



  reply	other threads:[~2015-02-18 22:31 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-17  4:42 [PATCH] Staging: rtl8188eu: Use put_unaligned_le16 Vaishali Thakkar
2015-02-17  9:02 ` [Outreachy kernel] " Arnd Bergmann
2015-02-17 10:11   ` Vaishali Thakkar
2015-02-17 19:12     ` Jes Sorensen
2015-02-18  1:32       ` Vaishali Thakkar
2015-02-18 10:50         ` Arnd Bergmann
2015-02-18 17:10           ` Jes Sorensen
2015-02-18 18:08             ` Vaishali Thakkar
2015-02-18 22:31               ` Jes Sorensen [this message]
2015-02-19  3:05                 ` Vaishali Thakkar
2015-02-19  8:28                   ` Arnd Bergmann
2015-02-19  8:43                     ` Vaishali Thakkar
2015-02-20 12:01                       ` Jes Sorensen

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=54E512AD.4040303@gmail.com \
    --to=jes.sorensen@gmail.com \
    --cc=arnd@arndb.de \
    --cc=outreachy-kernel@googlegroups.com \
    --cc=vthakkar1994@gmail.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: 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.