All of lore.kernel.org
 help / color / mirror / Atom feed
From: Karolina Drobnik <karolinadrobnik@gmail.com>
To: Julia Lawall <julia.lawall@inria.fr>
Cc: outreachy-kernel@googlegroups.com, gregkh@linuxfoundation.org,
	 forest@alittletooquiet.net
Subject: Re: [Outreachy kernel] [PATCH] staging: vt6655: Rename byPreambleType field
Date: Thu, 14 Oct 2021 18:45:31 +0100	[thread overview]
Message-ID: <08596422a73e37833b431fd5b922e7a02f6e4c0e.camel@gmail.com> (raw)
In-Reply-To: <alpine.DEB.2.22.394.2110141724560.3289@hadrien>

Hi,

On Thu, 2021-10-14 at 17:26 +0200, Julia Lawall wrote:
> On Thu, 14 Oct 2021, Karolina Drobnik wrote:
>
> > Drop Hungarian notation prefix in `byPreambleType` member of
> > struct vnt_private. Change it to use snake case.
>
> Are you sure that it is an instance of Hungarian notation?  Could it
> be that "by" is meant to be the word "by"?

I saw that functions and parameters use it[1] so I deduced that "by"
might stand for byte. If this is not a case, I can revert that change
and leave `by_preamble_type` name. What do you think?

> I have the imrepssion from a
> quick look through the code that it should be a boolean. 

Hmm, it really looks like it. In `vnt_bss_info_changed` definition we
use true/false values but in `bb_get_frame_time` we have such a line:

```
if (byPreambleType == 1)     /* Short */
```

I'm not quite sure to what this "short" might refer to.

> Maybe it  would be helpful to give it boolean value, 
> eg true instead of 1.

This is a good idea but I'm not sure if it's only used as a boolean. 
I could add this change but I'd like to test it more than just by
loading/unloading the module. Is there any way of testing drivers
without an actual hardware?


Thanks,
Karolina

----------------------------------------
[1] - For example in rxtx.c, lines 154-161:
```
static
unsigned int
s_uGetTxRsvTime(                     /* s - static, u - unsigned */
        struct vnt_private *pDevice, /* p - pointer */
        unsigned char byPktType,     /* by - byte */
        unsigned int cbFrameLength,  /* not sure */
        unsigned short wRate,        /* w - word */
        bool bNeedAck                /* b - boolean */
)
```



  reply	other threads:[~2021-10-14 17:45 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-14 15:15 [PATCH] staging: vt6655: Rename byPreambleType field Karolina Drobnik
2021-10-14 15:26 ` [Outreachy kernel] " Julia Lawall
2021-10-14 17:45   ` Karolina Drobnik [this message]
2021-10-14 18:40     ` Julia Lawall
2021-10-14 15:36 ` Greg KH
2021-10-14 17:47   ` Karolina Drobnik
2021-10-14 17:53     ` Greg KH
2021-10-15  8:32       ` Karolina Drobnik
2021-10-15  8:48         ` Julia Lawall
2021-10-15  8:52         ` [Outreachy kernel] " Mike Rapoport
2021-10-15  9:32           ` Karolina Drobnik
2021-10-15  9:33             ` Julia Lawall

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=08596422a73e37833b431fd5b922e7a02f6e4c0e.camel@gmail.com \
    --to=karolinadrobnik@gmail.com \
    --cc=forest@alittletooquiet.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=julia.lawall@inria.fr \
    --cc=outreachy-kernel@googlegroups.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.