driverdev-devel.linuxdriverproject.org archive mirror
 help / color / mirror / Atom feed
From: <Christian.Gromm@microchip.com>
To: <joe@perches.com>
Cc: devel@driverdev.osuosl.org, gregkh@linuxfoundation.org
Subject: Re: staging: most: configfs: PAGE_SIZE char arrays?
Date: Wed, 27 Nov 2019 10:33:00 +0000	[thread overview]
Message-ID: <1574850793.22988.31.camel@microchip.com> (raw)
In-Reply-To: <94ed28d75af8850171f2542d7170ca61001a9a8b.camel@perches.com>

On Di, 2019-11-26 at 11:30 -0800, Joe Perches wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you
> know the content is safe
> 
> drivers/staging/most/configfs.c:struct mdev_link {
> drivers/staging/most/configfs.c-        struct config_item item;
> drivers/staging/most/configfs.c-        struct list_head list;
> drivers/staging/most/configfs.c-        bool create_link;
> drivers/staging/most/configfs.c-        bool destroy_link;
> drivers/staging/most/configfs.c-        u16 num_buffers;
> drivers/staging/most/configfs.c-        u16 buffer_size;
> drivers/staging/most/configfs.c-        u16 subbuffer_size;
> drivers/staging/most/configfs.c-        u16 packets_per_xact;
> drivers/staging/most/configfs.c-        u16 dbr_size;
> drivers/staging/most/configfs.c-        char datatype[PAGE_SIZE];
> drivers/staging/most/configfs.c-        char direction[PAGE_SIZE];
> drivers/staging/most/configfs.c-        char name[PAGE_SIZE];
> drivers/staging/most/configfs.c-        char device[PAGE_SIZE];
> drivers/staging/most/configfs.c-        char channel[PAGE_SIZE];
> drivers/staging/most/configfs.c-        char comp[PAGE_SIZE];
> drivers/staging/most/configfs.c-        char comp_params[PAGE_SIZE];
> drivers/staging/most/configfs.c-};
> 
> Why are all the char arrays size PAGE_SIZE ?
> That seems completely unnecessary.

Right. Probably a bad habit when handling userspace.

thanks,
Chris
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

      reply	other threads:[~2019-11-27 10:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-26 19:30 staging: most: configfs: PAGE_SIZE char arrays? Joe Perches
2019-11-27 10:33 ` Christian.Gromm [this message]

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=1574850793.22988.31.camel@microchip.com \
    --to=christian.gromm@microchip.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=joe@perches.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).