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]
Message-ID: <YyMlovoskUcHLEb7@kroah.com>
Date:   Thu, 15 Sep 2022 15:16:18 +0200
From:   Greg KH <gregkh@...uxfoundation.org>
To:     наб <nabijaczleweli@...ijaczleweli.xyz>
Cc:     Bagas Sanjaya <bagasdotme@...il.com>,
        Jonathan Corbet <corbet@....net>,
        Federico Vaga <federico.vaga@...a.pv.it>,
        Alex Shi <alexs@...nel.org>,
        Yanteng Si <siyanteng@...ngson.cn>,
        Hu Haowen <src.res@...il.cn>,
        Thomas Gleixner <tglx@...utronix.de>,
        linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-doc-tw-discuss@...ts.sourceforge.net
Subject: Re: [PATCH v3] Documentation: remove magic number doc

On Thu, Sep 15, 2022 at 01:32:54AM +0200, наб wrote:
> The entire file blames back to the start of git
> (minus whitespace from the RST translation and a typo fix):
>   * there are changelog comments for March 1994 through to Linux 2.5.74
>   * struct tty_ldisc is two pointers nowadays, so naturally no magic
>   * GDA_MAGIC is defined but unused, and it's been this way
>     since start-of-git
>   * M3_CARD_MAGIC isn't defined, because
>     commit d56b9b9c464a ("[PATCH] The scheduled removal of some OSS
>     drivers") removed the entire driver in 2006
>   * CS_CARD_MAGIC likewise since
>     commit b5d425c97f7d ("more scheduled OSS driver removal") in 2007
>   * KMALLOC_MAGIC and VMALLOC_MAGIC were removed in
>     commit e38e0cfa48ac ("[ALSA] Remove kmalloc wrappers"),
>     six months after start of git
>   * SLAB_C_MAGIC has never even appeared in git
>     (removed in 2.4.0-test3pre6)
> 
> At a glance, the only ones still in use are in drivers which are mostly
> untouched since git (TTY, SLIP,
> SCSI (drivers/scsi/{arm/queue.c,ncr53c8xx.c}), &c.).
> 
> A rough estimate of magic numbers in the kernel is obtained by:
>   # git grep define | grep '_MAGIC\b' |
>     grep -ve IOC  -e ^tools/ -e '_IO[(WR]' -e _SUPER | wc -l
>   780
> Note that the word 'magic' may have different meaning from magic
> number context.
> There are also magic numbers which aren't listed here, like
> SR_EEPROM_MAGIC, L2TP_TUNNEL_MAGIC, and MD_SB_MAGIC.
> 
> Therefore, magic-number.rst is a low-value historial relic at best and
> misleading cruft at worst, so remove the documentation.
> 
> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@...ijaczleweli.xyz>

Please only remove the ones that are not used anymore.

Then work on actually removing the remaining ones (hint, the tty layer
should not need this and I'll gladly take patches), and only after they
are all gone, can you remove the whole file.

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ