Message ID | 20230705213010.390849-10-hdegoede@redhat.com (mailing list archive) |
---|---|
State | Superseded |
Headers |
Received: from vger.kernel.org ([23.128.96.18]) by www.linuxtv.org with esmtp (Exim 4.92) (envelope-from <linux-media-owner@vger.kernel.org>) id 1qHA6h-00CODK-Pi; Wed, 05 Jul 2023 21:32:16 +0000 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232346AbjGEVcN (ORCPT <rfc822;mkrufky@linuxtv.org> + 1 other); Wed, 5 Jul 2023 17:32:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37350 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232176AbjGEVcH (ORCPT <rfc822;linux-media@vger.kernel.org>); Wed, 5 Jul 2023 17:32:07 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BE3681BD6 for <linux-media@vger.kernel.org>; Wed, 5 Jul 2023 14:30:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1688592642; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0XDUjOHZokc15U6DFg/8LeQOr+/kSwwTjY+oa+J1w3M=; b=EcSCuGbbUEuLlGTrMCLALATzJ5Usi9w7TOSlQKhvz9Dj2B2yI0I4unTcwWNR8vm1E4tloK uSSlaNgP+NweiY1emMaq0xM0piHJdGh558h79qc0owlfBqc+a4l+NNVVx4F5w0NcOEabLz w9x7EmY5RGfnUlOXtcDkk/OnSJPU7jo= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-331-43yN5zOoNWCTqElOnVkkeQ-1; Wed, 05 Jul 2023 17:30:37 -0400 X-MC-Unique: 43yN5zOoNWCTqElOnVkkeQ-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.rdu2.redhat.com [10.11.54.1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 44464185A792; Wed, 5 Jul 2023 21:30:37 +0000 (UTC) Received: from localhost.localdomain (unknown [10.39.192.7]) by smtp.corp.redhat.com (Postfix) with ESMTP id B58DB40C2063; Wed, 5 Jul 2023 21:30:35 +0000 (UTC) From: Hans de Goede <hdegoede@redhat.com> To: "Rafael J . Wysocki" <rafael@kernel.org>, Sakari Ailus <sakari.ailus@linux.intel.com>, Laurent Pinchart <laurent.pinchart@ideasonboard.com>, Daniel Scally <dan.scally@ideasonboard.com> Cc: Hans de Goede <hdegoede@redhat.com>, linux-acpi@vger.kernel.org, Mauro Carvalho Chehab <mchehab@kernel.org>, Andy Shevchenko <andy@kernel.org>, Kate Hsuan <hpa@redhat.com>, Hao Yao <hao.yao@intel.com>, Bingbu Cao <bingbu.cao@intel.com>, linux-media@vger.kernel.org Subject: [PATCH v3 09/18] media: ipu-bridge: Drop early setting of sensor->adev Date: Wed, 5 Jul 2023 23:30:01 +0200 Message-ID: <20230705213010.390849-10-hdegoede@redhat.com> In-Reply-To: <20230705213010.390849-1-hdegoede@redhat.com> References: <20230705213010.390849-1-hdegoede@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.1 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-media.vger.kernel.org> X-Mailing-List: linux-media@vger.kernel.org X-LSpam-Score: -4.8 (----) X-LSpam-Report: No, score=-4.8 required=5.0 tests=BAYES_00=-1.9,DKIMWL_WL_HIGH=0.001,DKIM_SIGNED=0.1,DKIM_VALID=-0.1,DKIM_VALID_AU=-0.1,HEADER_FROM_DIFFERENT_DOMAINS=0.5,MAILING_LIST_MULTI=-1,RCVD_IN_DNSWL_MED=-2.3 autolearn=ham autolearn_force=no |
Series |
media: ipu-bridge: Shared with atomisp, rework VCM instantiation
|
|
Commit Message
Hans de Goede
July 5, 2023, 9:30 p.m. UTC
sensor->adev is no longer dereferenced before it is permanently set by:
sensor->adev = acpi_dev_get(adev);
So the early assignment with a borrowed reference can be dropped.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/pci/intel/ipu-bridge.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/media/pci/intel/ipu-bridge.c b/drivers/media/pci/intel/ipu-bridge.c index ee0ca5e6e33b..1f01f2c8b8a6 100644 --- a/drivers/media/pci/intel/ipu-bridge.c +++ b/drivers/media/pci/intel/ipu-bridge.c @@ -342,11 +342,6 @@ static int ipu_bridge_connect_sensor(const struct ipu_sensor_config *cfg, } sensor = &bridge->sensors[bridge->n_sensors]; - /* - * Borrow our adev ref to the sensor for now, on success - * acpi_dev_get(adev) is done further below. - */ - sensor->adev = adev; ret = ipu_bridge_parse_ssdb(adev, sensor); if (ret)