kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Muni Sekhar <munisekharrms@gmail.com>
Cc: arnd@arndb.de, kernelnewbies <kernelnewbies@kernelnewbies.org>
Subject: Re: drivers/char/efirtc.c - efi_rtc_open\ efi_rtc_close
Date: Mon, 21 Jan 2019 11:28:53 +0100	[thread overview]
Message-ID: <20190121102853.GA15590@kroah.com> (raw)
In-Reply-To: <CAHhAz+g7YL1E9x2_Fqu=j6ENkoFChBkAO+hO6fhvxy-Z5JiFvw@mail.gmail.com>

On Mon, Jan 21, 2019 at 03:40:31PM +0530, Muni Sekhar wrote:
> Hello All,
> 
> The drivers/char/efirtc.c file has ‘struct file_operations.open’ & ‘struct
> file_operations.close’ functions efi_rtc_open()\ efi_rtc_close() does
> nothing, just returns ‘0’.
> 
> So it accept multiple open files at the same time. If we don’t define these
> empty function, still driver accepts multiple open() calls at the same
> time, right?
> 
> If so I’d like to know what is the advantage of keeping these function
> which does nothing instead of removing it from driver?

There is no advantage at all, those functions can be removed safely, no
need to have them at all.  Care to send a patch for this?

thanks,

greg k-h

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

      reply	other threads:[~2019-01-21 10:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-21 10:10 drivers/char/efirtc.c - efi_rtc_open\ efi_rtc_close Muni Sekhar
2019-01-21 10:28 ` Greg KH [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=20190121102853.GA15590@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=arnd@arndb.de \
    --cc=kernelnewbies@kernelnewbies.org \
    --cc=munisekharrms@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 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).