Received: by 2002:a05:6358:489b:b0:bb:da1:e618 with SMTP id x27csp773961rwn; Thu, 15 Sep 2022 06:21:58 -0700 (PDT) X-Google-Smtp-Source: AA6agR5sXMweCHVtdbNQtJBffNVAx0nqmPGuZwB2zD7qlBTMc0ADI1x3KcT4frrBPhNIqQx6ptef X-Received: by 2002:a17:907:3da2:b0:780:48ae:e77c with SMTP id he34-20020a1709073da200b0078048aee77cmr3642976ejc.516.1663248117920; Thu, 15 Sep 2022 06:21:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663248117; cv=none; d=google.com; s=arc-20160816; b=DsfXXa9M03wpxJC5Cm4/x77Ti1yjLGfWrfUV5Dfi23hP5d4ZYalRTLJQJar3Hlhatk xRWx3S9Elc78+P72He0y0rG477a7deBbU7o1GszZ08hcMdv5AlJcoz/BktjovXi+RGW2 zYv/CywxlEWL4yNQWGpOECVrXIpmNovze3uRCTPsgZueIMwEx1X8DzuGByXGNGJzDWHV m3XaB1Sw4Xe9V081BEv9/a/un/BqwCkunL4TaOI6GVCC1Dk3Rhc0aFfUyX7HqzRKx+nx OuXtEFNOwrA2EqzN2/gACMPMi7uz4hlGzNqBkKGxbYOulCehX0FXrQL1oLY1h7dRhAdM /FPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=l1rFnLd2D2X5226c2jVx4hETtwoz79+jhsO5XLOi6v8=; b=eLok/gMntRg6h4hPZJPw60wSt4/nDlTzeIRHbRGocYj3FpDLNL9S7qolbuchJOGtV7 OBxA2YtFt5ICm9S0H6f5IwXKMHuMAmFXVFUZXIYLbmFU8euLM8PdLN4Bx/mj7qcn04oz pVGWLjf1+Ygb5G9GnymI+bduW4ok1mrQ+HecV53fRKAoInD1dC9CgFbGBRXc4QA9jHy0 pG2/PJ21IfZEx13thSLHSAmp3war/z/NOD2CwLUZnJmb/pxdNvBv0fxudzg/l9UwJLIV GL8Ip8sbdltqN/5wr8paTVjkQwgfSsV9OcPooksD98Ysmzh7TEH2RY43Pfa/WuDJQrHK GsYQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=DUBaRJeO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q9-20020a056402518900b0045249bc17eesi7895770edd.589.2022.09.15.06.21.27; Thu, 15 Sep 2022 06:21:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=DUBaRJeO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229809AbiIONP6 (ORCPT + 99 others); Thu, 15 Sep 2022 09:15:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229682AbiIONP4 (ORCPT ); Thu, 15 Sep 2022 09:15:56 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E5C4854C82; Thu, 15 Sep 2022 06:15:54 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 97BC3B8200F; Thu, 15 Sep 2022 13:15:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id CC51CC433D6; Thu, 15 Sep 2022 13:15:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1663247752; bh=D99hEJwO1zg9kh/dzIgxfTC45cTYP3GG0gTzAtC2HGA=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=DUBaRJeOmWDtl4Zx9/FCXZUMTevnyyFhK4aENnzetz0tBhjQizwVpnJLtbemjYix9 1OL70DsII4MdyZ2K/fPnSvYNqdfC3lUo7tJ/0Xd1aYLH1Bz9Es0BkoRESDQf9dmAR6 DrM31CjAuMHphyWumv12TgXKWX/LCGbMpeKmQcws= Date: Thu, 15 Sep 2022 15:16:18 +0200 From: Greg KH To: =?utf-8?B?0L3QsNCx?= Cc: Bagas Sanjaya , Jonathan Corbet , Federico Vaga , Alex Shi , Yanteng Si , Hu Haowen , Thomas Gleixner , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc-tw-discuss@lists.sourceforge.net Subject: Re: [PATCH v3] Documentation: remove magic number doc Message-ID: References: <731a3b01-1ade-6003-eb21-6b0a2c919750@gmail.com> <20220914233254.zcuaw23nl2wgs7f3@tarta.nabijaczleweli.xyz> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20220914233254.zcuaw23nl2wgs7f3@tarta.nabijaczleweli.xyz> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 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