From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.13]) (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 DA82C1FB4; Thu, 14 Mar 2024 02:26:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.13 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710383210; cv=none; b=tXc/KpRj/JZkI44J2Lpfcw5YNPS8kQaqhFA6dMPNFwUtvclZSsG07rPJGsjOuZfarP4XxJlST1UvVoWKMnNCG0dWvM8ia0HkszCtP0ZM3j0zkvuYwfi3zFY/DFQdmcoDBe/zmEXsFUjz0OPrI9ZBteO4Eo1gUhKStlBo0avipF8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710383210; c=relaxed/simple; bh=isznYQj6c1rnwEUqLiHaDxS2i6jtXknSZw3ne+WB6UA=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=YvLt3krmt2xi8IOA0+SXoXsLdPdZThY7CgSXP7N+fcqkV3PJkfjJ5NWj80+R9+3BZqbQLPOiJFHjj3RpIT/zrUOuF/rncNRFGgqtduD/SQsSKUDqIlMR3hMaSUt+qVxAhOPsZG3cobOwoB5O23WndEEz7t72QrU999gb9XVWm5c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com; spf=pass smtp.mailfrom=intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=Ez3ozUTc; arc=none smtp.client-ip=198.175.65.13 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="Ez3ozUTc" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1710383210; x=1741919210; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=isznYQj6c1rnwEUqLiHaDxS2i6jtXknSZw3ne+WB6UA=; b=Ez3ozUTco27ddqdrQHZOset7S6uAlU6yzlEhePuRFd8terJHM2IhNzq2 7hiltiqqdCZ77mkc8LwnNSe4gNc+E/bhSXcSwH4axSPMAVp407tOw0sSu U4LtIQvpaWKTCsg1SB3g/vV15gRWIEAK8zG0oFlBl4XdU5YGkAIBt9L37 o4m50Rt1IM1aQkEy+NhTXSfpM86O/LTzLvmol5Pz4b8yorr8mAQ9Gj0eu hnokvcaKdm15MulOBQqkufLlvBVL4Ilwb/AmHtM/8Sl8xnIamWADPLH85 0b6C8EdMQ6tWoccCgglEnGbnNjrhEHyEaR1Q3TQ7WLQfwiO0D5+UD3rcV A==; X-IronPort-AV: E=McAfee;i="6600,9927,11012"; a="16341236" X-IronPort-AV: E=Sophos;i="6.07,124,1708416000"; d="scan'208";a="16341236" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by orvoesa105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Mar 2024 19:25:51 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,124,1708416000"; d="scan'208";a="12152202" Received: from aschofie-mobl2.amr.corp.intel.com (HELO aschofie-mobl2) ([10.209.86.131]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Mar 2024 19:25:49 -0700 Date: Wed, 13 Mar 2024 19:25:47 -0700 From: Alison Schofield To: Ayush Tiwari Cc: Larry.Finger@lwfinger.net, florian.c.schilhabel@googlemail.com, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev, outreachy@lists.linux.dev Subject: Re: [PATCH] staging: greybus: add const type to struct kobj_type gb_audio_module_type Message-ID: References: Precedence: bulk X-Mailing-List: linux-staging@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Thu, Mar 14, 2024 at 12:32:57AM +0530, Ayush Tiwari wrote: > Add type qualifier const in struct kobj_type gb_audio_module_type to > address checkpatch warning and conform to the kernel coding style. Thanks for the patch. A couple of things you could address in a v2: 1) 'Constify' is not a real English word, or maybe it's made its way into an urban dictionary by now. Anyway, it's a common patch action and you can read more about and improve the 'why' in your description. Try: $ git log --pretty=oneline --abbrev-commit | grep Constify and you'll find many patch examples. I think you'll find a crisper 'why' for your patch description. Also, here's a former Outreachy Interns blog about the topic: https://medium.com/@bhumikagoyal/linux-kernel-const-annotation-8db591148e58 2) Now that you know about the work 'Constify' please use it in your commit message so that it doesn't cause line wrap (80 lines) when doing $ git log --pretty=oneline --abbrev-commit audio_manager_module.c See the First Patch Tutorial Section: Following the Driver commit style Alison > > Signed-off-by: Ayush Tiwari > --- > drivers/staging/greybus/audio_manager_module.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/staging/greybus/audio_manager_module.c b/drivers/staging/greybus/audio_manager_module.c > index 5f9dcbdbc191..4a4dfb42f50f 100644 > --- a/drivers/staging/greybus/audio_manager_module.c > +++ b/drivers/staging/greybus/audio_manager_module.c > @@ -144,7 +144,7 @@ static struct attribute *gb_audio_module_default_attrs[] = { > }; > ATTRIBUTE_GROUPS(gb_audio_module_default); > > -static struct kobj_type gb_audio_module_type = { > +static const struct kobj_type gb_audio_module_type = { > .sysfs_ops = &gb_audio_module_sysfs_ops, > .release = gb_audio_module_release, > .default_groups = gb_audio_module_default_groups, > -- > 2.40.1 > >