lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 28 Jun 2017 17:02:14 +0200
From:   Samuel Thibault <samuel.thibault@...-lyon.org>
To:     walter harms <wharms@....de>
Cc:     Colin King <colin.king@...onical.com>,
        William Hubbs <w.d.hubbs@...il.com>,
        Chris Brannon <chris@...-brannons.com>,
        Kirk Reiser <kirk@...sers.ca>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Okash Khawaja <okash.khawaja@...il.com>,
        Andy Shevchenko <andy.shevchenko@...il.com>,
        Alexandre Ghiti <alex@...ti.fr>,
        Dan Carpenter <dan.carpenter@...cle.com>,
        Rui Teng <rui.teng@...ux.vnet.ibm.com>,
        speakup@...ux-speakup.org, devel@...verdev.osuosl.org,
        kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] staging: speakup: make function ser_to_dev static

walter harms, on mer. 28 juin 2017 16:49:03 +0200, wrote:
> Am 28.06.2017 15:13, schrieb Colin King:
> > diff --git a/drivers/staging/speakup/spk_ttyio.c b/drivers/staging/speakup/spk_ttyio.c
> > index 442f191a017e..ed8e96b06ead 100644
> > --- a/drivers/staging/speakup/spk_ttyio.c
> > +++ b/drivers/staging/speakup/spk_ttyio.c
> > @@ -21,7 +21,7 @@ struct spk_ldisc_data {
> >  static struct spk_synth *spk_ttyio_synth;
> >  static struct tty_struct *speakup_tty;
> >  
> > -int ser_to_dev(int ser, dev_t *dev_no)
> > +static int ser_to_dev(int ser, dev_t *dev_no)
> >  {
> >  	if (ser < 0 || ser > (255 - 64)) {
> >  		pr_err("speakup: Invalid ser param. Must be between 0 and 191 inclusive.\n");
> 
> 
> Is there any remark, why the programmer decided to use (255 - 64) instead of 191 ?

That's because minor numbers for ttyS* are starting from 64.

Samuel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ