Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758280Ab1EABh7 (ORCPT ); Sat, 30 Apr 2011 21:37:59 -0400 Received: from mail-ww0-f44.google.com ([74.125.82.44]:52252 "EHLO mail-ww0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753419Ab1EABhQ (ORCPT ); Sat, 30 Apr 2011 21:37:16 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; b=F4P0SQJtyqTeiXzHaPrQE35GUwVarMEc/V8XnenGB6/FifFXAkzrQLayNkQWUbhrwC hRoBBlOLlakPYIJlnxT3VoO3jRlq/3lWM0YGC8fcE56Bh4SJ6tQjZ7+olnF4Aj+7Gqoy NQYD1degZX0oLPKlrmPpgwWn+yNdlnmd4VbbQ= From: Lucian Adrian Grijincu To: linux-kernel@vger.kernel.org Cc: Lucian Adrian Grijincu Subject: [PATCH 09/69] sysctl: remove .child from dev/cdrom/ Date: Sun, 1 May 2011 03:35:39 +0200 Message-Id: <1304213799-10257-10-git-send-email-lucian.grijincu@gmail.com> X-Mailer: git-send-email 1.7.5.134.g1c08b In-Reply-To: <1304213799-10257-1-git-send-email-lucian.grijincu@gmail.com> References: <1304213799-10257-1-git-send-email-lucian.grijincu@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1516 Lines: 56 Signed-off-by: Lucian Adrian Grijincu --- drivers/cdrom/cdrom.c | 22 ++++------------------ 1 files changed, 4 insertions(+), 18 deletions(-) diff --git a/drivers/cdrom/cdrom.c b/drivers/cdrom/cdrom.c index 514dd8e..9560789 100644 --- a/drivers/cdrom/cdrom.c +++ b/drivers/cdrom/cdrom.c @@ -3654,26 +3654,12 @@ static ctl_table cdrom_table[] = { { } }; -static ctl_table cdrom_cdrom_table[] = { - { - .procname = "cdrom", - .maxlen = 0, - .mode = 0555, - .child = cdrom_table, - }, +static const struct ctl_path cdrom_root_path[] = { + { .procname = "dev" }, + { .procname = "cdrom" }, { } }; -/* Make sure that /proc/sys/dev is there */ -static ctl_table cdrom_root_table[] = { - { - .procname = "dev", - .maxlen = 0, - .mode = 0555, - .child = cdrom_cdrom_table, - }, - { } -}; static struct ctl_table_header *cdrom_sysctl_header; static void cdrom_sysctl_register(void) @@ -3683,7 +3669,7 @@ static void cdrom_sysctl_register(void) if (initialized == 1) return; - cdrom_sysctl_header = register_sysctl_table(cdrom_root_table); + cdrom_sysctl_header = register_sysctl_paths(cdrom_root_path, cdrom_table); /* set the defaults */ cdrom_sysctl_settings.autoclose = autoclose; -- 1.7.5.134.g1c08b -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/