From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D41CB6F099 for ; Mon, 15 Jul 2024 20:58:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=159.69.126.157 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1721077104; cv=none; b=qMAM5YUSMm5Um1JVDdzgcgGxnigeAVxBXqDQ8An1nn/NJc9KLOmmuaoC+mKphf3Z2D0Pvle6SNGrF8uYS1iYhik3cm/GkVe7P4v6+oXQqZXUdYNilcskFFEfUPW6NgLpnKw35Sr9iRP6TjKVu3bma5VrZFhvoRIgGUmygWNbBRc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1721077104; c=relaxed/simple; bh=tBfLRwUKojVWwnqq++F5SNw6DeFH1PgqRMLYEUmhsMk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=TQsDD2ThGtIFA7wtBKhUdrbGsyrMhR19Og230S/TTJ3YbjN9yYs7mQyhMpxYQck//CT4E8yp5NxEVDH8ASD/Tlk9t/RB7cn2EVECqYaLKWiYR2Yxo4ZA2JqYohqV8zTg1Q+YfZNHBjP//4PRsw22efo7q+pKg5sgaJE5VHAXbJE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net; spf=pass smtp.mailfrom=weissschuh.net; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b=g2ELljR3; arc=none smtp.client-ip=159.69.126.157 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b="g2ELljR3" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=weissschuh.net; s=mail; t=1721077090; bh=tBfLRwUKojVWwnqq++F5SNw6DeFH1PgqRMLYEUmhsMk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=g2ELljR3kyZcaRIzErFtJtRVf3jJxJ2CtWNDhIvhzpo3FP70YT3fKXUWeuXf5wUQr xTtHFWbbbddCgyA9Nzuay3giiIabcrDRZt1iEsqVeE3d/y2Fsdnu+/x01PiJw6aHj6 XJ2YTGncT9sGbV0MDWbeG9XdNnu8qO7W1QwhvGXk= Date: Mon, 15 Jul 2024 22:58:10 +0200 From: Thomas =?utf-8?Q?Wei=C3=9Fschuh?= To: Joel Granados Cc: Luis Chamberlain , Kees Cook , Andrew Morton , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] sysctl: treewide: constify the ctl_table argument of proc_handlers Message-ID: References: <20240619-sysctl-const-handler-v2-1-e36d00707097@weissschuh.net> <20240715202319.mccb6jlsa6dkynap@joelS2.panther.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20240715202319.mccb6jlsa6dkynap@joelS2.panther.com> On 2024-07-15 22:23:19+0000, Joel Granados wrote: > On Wed, Jun 19, 2024 at 12:09:00PM +0200, Thomas Weißschuh wrote: > > Adapt the proc_hander function signature to make it clear that handlers > > are not supposed to modify their ctl_table argument. > > > > This is also a prerequisite to moving the static ctl_table structs into > > read-only data. > > > > The patch was mostly generated by coccinelle with the following script: > > > > @@ > > identifier func, ctl, write, buffer, lenp, ppos; > > @@ > > > > int func( > > - struct ctl_table *ctl, > > + const struct ctl_table *ctl, > > int write, void *buffer, size_t *lenp, loff_t *ppos) > > { ... } > > > > In addition to the scripted changes some other changes are done: > > > > * The "typedef proc_handler" in include/linux/sysctl.h is changed to use > > the "const ctl_table". > > > > * The prototypes of non-static handlers in header-files are adapted > > to match the changes of their respective definitions. > > > > * kernel/watchdog.c: proc_watchdog_common() > > This is called from a proc_handler itself and is als calling back > > into another proc_handler, making it necessary to change it as part > > of the proc_handler migration. > > > > No functional change. > > > > Signed-off-by: Thomas Weißschuh > > --- > > The merge window is now open. I want to send this patch on the Wednesday > of next week (jul 24). Sounds good. > @Thomas: Some questions > > 1. Are there any updates? No. > 2. Does it still apply cleanly against the latest master branch? Not against mainline master, but against next-20240715. To apply cleanly (and compile) on mainline master it still requires the net/ and sysctl trees to be merged. Otherwise some modified functions are missing, leading to (trivial) merge conflicts or the preparation commits are missing, leading to compilation errors. > 3. Are you able to do the last update at the beginning of next week (Jul > 22)? Sure. Thomas