Message ID | 20231025111806.2416524-4-michal.wilczynski@intel.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:ce89:0:b0:403:3b70:6f57 with SMTP id p9csp2523617vqx; Wed, 25 Oct 2023 04:19:12 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFu3p/a9EfrFmBGjyVhCth4hlUxxFHdjKCHQrkfunffcKizamI33oFbqmG0ZbAZfrIyjhgE X-Received: by 2002:a05:6808:2d1:b0:3ae:3d0:d74a with SMTP id a17-20020a05680802d100b003ae03d0d74amr16214338oid.52.1698232752495; Wed, 25 Oct 2023 04:19:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698232752; cv=none; d=google.com; s=arc-20160816; b=JSS6d0EyNowj0Oy87jpX+WAOP9E+kbMeVxk4wvxVoBulsepFCJEy9f/Rn8Hdx73T09 F1v3gWc86V6fExw2W+zf4/CqAwLRYbtc1lbVgB02f1d8u5j44EDOwq6h7z/526bC9flm aaLC3XUGqVgYd3Y4VgBZcNPCVns3EfKlApHT8xyQ3wThNv7pvO8pcgK3JHdjfbFeGJTo zYsAcT5/fM8DoKkTqvMJXOe7jx5HRU0wExSmqyFbKNzwG0/DXqRoZ6EYV+gNy4TpYgqa 2UJ8btjLWWrNh5JMASkZ6BBAVIF77X48rxXzqXM9rCFDXX110qk052Y1K0jg/2jWmzby BD/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=zni4MC39mFQuWv1PNE4ESe3BI304dg591sjjGItxG4c=; fh=yqoav7EnEdJ2mT+rtoecryk3HwWdUT86ZBxH2AVEvUc=; b=IW+Dggz2RajvuDZ1AkJaWNRmdUE+WLde7/5bENoBY0Ko60Zch8Vdgdy+WYx52J1myf fPeWYuMy8msWpzdW9Sb1JyTyr6HrzIhghurvWyM/BseZB+4VI7R17ICtCui2JdNV0FF+ 5WLzggf98JdbplamX99+ZS9ZQ3RGebqdlirAuVzUQKSuh14y4KfSSkAh8Bd2X1DcEe8M 8UsDZpk8Iz9aJMfOMP6QyAFM/Gc5qDvitQm9DXn5I0XTRHE+rTzkmxxIYfTjdAOzfo9P 6NGNXnyRhDU4fzrQOfh8bLJkyRjkSULTI2XsYGOlROsnjvUrG3ua9JZdyQQGhY8FEtDH RGyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=XVnH2i6y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id d4-20020a25cd04000000b00da086e8ae8fsi618679ybf.621.2023.10.25.04.19.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Oct 2023 04:19:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=XVnH2i6y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 9365980E7625; Wed, 25 Oct 2023 04:19:09 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234782AbjJYLSs (ORCPT <rfc822;aposhian.dev@gmail.com> + 26 others); Wed, 25 Oct 2023 07:18:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58128 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233804AbjJYLSj (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 25 Oct 2023 07:18:39 -0400 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CEF50137; Wed, 25 Oct 2023 04:18:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1698232716; x=1729768716; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=GGWBLv1O7SHoGXNqpswjaidLqIzwApROs0cSW0Fp2r8=; b=XVnH2i6yhtAz/hY4hA0WS3OjmJbRC8Vi1L0e9WESRTIgx0xzGyvQdSdh ICZoR7QVgZJ6oduA7tWm0bpO4sTbbpAfBMgkSam53mK0peLfQIWRQGoLs iO/p6RBo/+BcI3Mi0NcR460Rm90FzkfA5vROZNb2Y3lUwFRBAt7O7JxGH udpKh6LqZS/++FPM9jZ8kpueie9omX0N52aLVeUeFTYWsSkBWdByDq+Hz QKsxaG+A604I67LIaXT918sT78A5daxmWE5GrIuH/26N5A9wV1JLFx+XD SlHwU92WkvO9x0PBbqlZMe8Hx8lsU+vC0jkY0RHBi19pa5FPc0UJqRroO Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10873"; a="391154628" X-IronPort-AV: E=Sophos;i="6.03,250,1694761200"; d="scan'208";a="391154628" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Oct 2023 04:18:24 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10873"; a="762425103" X-IronPort-AV: E=Sophos;i="6.03,250,1694761200"; d="scan'208";a="762425103" Received: from powerlab.fi.intel.com ([10.237.71.25]) by fmsmga007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Oct 2023 04:18:22 -0700 From: Michal Wilczynski <michal.wilczynski@intel.com> To: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org Cc: rafael.j.wysocki@intel.com, andriy.shevchenko@linux.intel.com, lenb@kernel.org, Michal Wilczynski <michal.wilczynski@intel.com> Subject: [PATCH v1 3/6] ACPI: acpi_video: Remove unnecessary driver_data clear Date: Wed, 25 Oct 2023 14:18:03 +0300 Message-ID: <20231025111806.2416524-4-michal.wilczynski@intel.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20231025111806.2416524-1-michal.wilczynski@intel.com> References: <20231025111806.2416524-1-michal.wilczynski@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Wed, 25 Oct 2023 04:19:09 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1780726106824100500 X-GMAIL-MSGID: 1780726106824100500 |
Series |
Replace acpi_driver with platform_driver
|
|
Commit Message
Wilczynski, Michal
Oct. 25, 2023, 11:18 a.m. UTC
Commit
0d16710146a1 ("ACPI: bus: Set driver_data to NULL every time .add() fails")
introduced clearing driver_data every time probe fails, so it's not
necessary to clear it in the probe() callback.
Remove NULL assignment to driver_data in error path in
acpi_video_bus_add().
Signed-off-by: Michal Wilczynski <michal.wilczynski@intel.com>
---
drivers/acpi/acpi_video.c | 1 -
1 file changed, 1 deletion(-)
Comments
On Wed, Oct 25, 2023 at 02:18:03PM +0300, Michal Wilczynski wrote: > Commit > 0d16710146a1 ("ACPI: bus: Set driver_data to NULL every time .add() fails") It's fine to wrap it here, it's just a restriction in the tag block that one tag == one line. Also I believe the form "The commit" sounds more English :-) as reader knows exact commit we are talking about. > introduced clearing driver_data every time probe fails, so it's not > necessary to clear it in the probe() callback. > Remove NULL assignment to driver_data in error path in > acpi_video_bus_add(). This can be one line.
diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c index e17474949bbb..0c93b0ef0feb 100644 --- a/drivers/acpi/acpi_video.c +++ b/drivers/acpi/acpi_video.c @@ -2077,7 +2077,6 @@ static int acpi_video_bus_add(struct acpi_device *device) kfree(video->attached_array); err_free_video: kfree(video); - device->driver_data = NULL; return error; }