Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756788Ab1DVWoR (ORCPT ); Fri, 22 Apr 2011 18:44:17 -0400 Received: from mga11.intel.com ([192.55.52.93]:16446 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753493Ab1DVWoQ (ORCPT ); Fri, 22 Apr 2011 18:44:16 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.64,256,1301900400"; d="scan'208";a="682730006" Subject: Re: [PATCH] export kernel call get_task_comm(). From: J Freyensee Reply-To: james_p_freyensee@linux.intel.com To: David Rientjes Cc: akpm@linux-foundattion.org, gregkh@suse.de, linux-kernel@vger.kernel.org, suhail.ahmed@intel.com, christophe.guerard@intel.com In-Reply-To: References: <1303511188-728-2-git-send-email-james_p_freyensee@linux.intel.com> Content-Type: text/plain; charset="ISO-8859-1" Date: Fri, 22 Apr 2011 15:43:59 -0700 Message-ID: <1303512239.13457.123.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.28.2 (2.28.2-1.fc12) Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1212 Lines: 27 On Fri, 2011-04-22 at 15:35 -0700, David Rientjes wrote: > On Fri, 22 Apr 2011, james_p_freyensee@linux.intel.com wrote: > > > From: J Freyensee > > > > This allows drivers who call this function to be compiled modularly. > > Otherwise, a driver who is interested in this type of functionality > > has to implement their own get_task_comm() call, causing code > > duplication in the Linux source tree. > > > > Signed-off-by: J Freyensee > > Acked-by: David Rientjes > > I still suggest that we implement finer-grained protection for tsk->comm > through get_task_comm(), though, because it's going to be difficult to > know whether task_lock(tsk) is held in all contexts we'll want to call it; > task_lock(tsk) is used to protect many members of task_struct. Okay, but how about accepting this as step 1, then investigate a finer grained lock structure as step 2? -- 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/