Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S266163AbUAVDbJ (ORCPT ); Wed, 21 Jan 2004 22:31:09 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S266169AbUAVD3b (ORCPT ); Wed, 21 Jan 2004 22:29:31 -0500 Received: from dp.samba.org ([66.70.73.150]:8172 "EHLO lists.samba.org") by vger.kernel.org with ESMTP id S266159AbUAVD30 (ORCPT ); Wed, 21 Jan 2004 22:29:26 -0500 From: Rusty Russell To: Andi Kleen Cc: Vojtech Pavlik , linux-kernel@vger.kernel.org, akpm@osdl.org Subject: Re: 2.6.1-mm4 In-reply-to: Your message of "Wed, 21 Jan 2004 13:46:57 BST." <20040121134657.6cd27cbd.ak@suse.de> Date: Thu, 22 Jan 2004 12:31:14 +1100 Message-Id: <20040122032941.2C6F12C259@lists.samba.org> Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1016 Lines: 28 In message <20040121134657.6cd27cbd.ak@suse.de> you write: > As for the implementation of doing it at runtime - i took a look at > it but got scared by sysfs livetime rules and the lack of callbacks > in module_parm. FYI module_parm is just a convenience wrapper around module_param_call(name, set, get, arg, perm) Where get and set are the callbacks: /* Returns 0, or -errno. arg is in kp->arg. */ typedef int (*param_set_fn)(const char *val, struct kernel_param *kp); /* Returns length written or -errno. Buffer is 4k (ie. be short!) */ typedef int (*param_get_fn)(char *buffer, struct kernel_param *kp); With these the implementation should be fairly neat. Hope that clarifies, Rusty. -- Anyone who quotes me in their sig is an idiot. -- Rusty Russell. - 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/