Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp377132rdh; Sat, 23 Sep 2023 14:50:34 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF3Kwxsjf48pjspBkKgA2tnUppRlkJ/P8a9RAm9bA/x7yo1D+nbwQ/vt90+oe7d6sP3n4lL X-Received: by 2002:a05:6a20:9154:b0:159:c2d0:9fc6 with SMTP id x20-20020a056a20915400b00159c2d09fc6mr3673032pzc.8.1695505833665; Sat, 23 Sep 2023 14:50:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695505833; cv=none; d=google.com; s=arc-20160816; b=aBroA19DCF9PPnP4y8ORWECcDCQyH/6YvYpARmpweMNgOdzSNekfrJ1QkYAsTRodMw I+YpDzafBkniIU91RtDfY3c0xL6xOR5mgiDnSv6urUiu2jffebMc8g5F712Tc25cFzVn EqiW0F5UpU45BoX1desP5AzUmcMed5FfgpwFeU8Yc7I//A5dDdDG0QvbuhdpRDWY8oXU sbgEzXshsvcqq9Hav2mssbHJu4QEuzW7tH9O4LaMY1ulFYEIENmqNd4XasKmvYH35nE/ K9fP6jW73p8QbJrjUNLEmIiimwz4UB8juL6k0tKMJRC8pgKNW3SdMCWNzrsTdumfo8YL 8XYg== 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=fFdSZp/RAv5y+kwIQcxN3x8BkNjNF+sSvrjAIb4DDW8=; fh=x1hGPnZeYvyedQGDVaFY4F5NZX5OfdEJxyYqoMYIkPY=; b=WZ0Wavs0p2PLp58Kpv+WcRHAZDZihUiQZp9cWevZFPQa7SCRZvrOteJdlQCYHTxlzV GxNygM/rXxpG8MGQddVUVNtsTFEPLo2eSxiWufWYSkKvEMC6AsT9zEfAshfC3BdxEqZN QNs493LDKMAX+AOgAwk5PLfM5Na5BqWK4foZl3TZLyjGgjJMXI4ObRb241v/FMlv9Xnk lNcdVJNdwoqq7O9yeLdLvvx0iDg7Xuw31FrG6CE4A32PgnXCjszJcwXgotxKebfIIN/R HlglS78Z0LcRwCtIG1EpxdOsIP4BlsXHmNVMAynw5wgxKGyjJx77Db+wCf4Rr1miK/0G B8tg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=i0Uuzwne; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id fc14-20020a056a002e0e00b0068ff333d768si6967752pfb.384.2023.09.23.14.50.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Sep 2023 14:50:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=i0Uuzwne; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 4499D80981BD; Sat, 23 Sep 2023 07:32:31 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231815AbjIWOc0 (ORCPT + 99 others); Sat, 23 Sep 2023 10:32:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58270 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231772AbjIWOcU (ORCPT ); Sat, 23 Sep 2023 10:32:20 -0400 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B1CDD113; Sat, 23 Sep 2023 07:32:12 -0700 (PDT) Received: from umang.lan (unknown [IPv6:2001:818:e7d2:8300:2412:6733:7e63:fb46]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id A1D831536; Sat, 23 Sep 2023 16:30:29 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1695479430; bh=OiS/6vUN9OZ5WEDhF9ICm3EsH9faDTmVyUTUv11Lyjg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=i0Uuzwneh5WRhM44uyo608ZSSywQ7WhkGMFNG8AIQHznLDIuZXZX2EE/aMykvcqxv MLE0+DaqVQBKGi2FMYaSmUuSwbAK1CgMGIgGeCbBZBzptmBpXoCGumVYDQAy8GTWo/ B5NAriMoauRDbuJdeIfB47H7mfaMnK1s/NCKeTjM= From: Umang Jain To: linux-staging@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-rpi-kernel@lists.infradead.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Stefan Wahren , Greg Kroah-Hartman , Florian Fainelli , Adrien Thierry , Dan Carpenter , Dave Stevenson , Kieran Bingham , Laurent Pinchart , Umang Jain Subject: [PATCH v12 4/6] staging: vc04_services: vchiq_arm: Register vchiq_bus_type Date: Sat, 23 Sep 2023 20:01:58 +0530 Message-Id: <20230923143200.268063-5-umang.jain@ideasonboard.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230923143200.268063-1-umang.jain@ideasonboard.com> References: <20230923143200.268063-1-umang.jain@ideasonboard.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS 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: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Sat, 23 Sep 2023 07:32:31 -0700 (PDT) Register the vchiq_bus_type bus with the vchiq interface. The bcm2835-camera and bcm2835_audio will be registered to this bus type going ahead. Signed-off-by: Umang Jain Reviewed-by: Kieran Bingham --- .../vc04_services/interface/vchiq_arm/vchiq_arm.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c index aa2313f3bcab..9388859b9b56 100644 --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c +++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include @@ -33,6 +34,7 @@ #include "vchiq_core.h" #include "vchiq_ioctl.h" #include "vchiq_arm.h" +#include "vchiq_bus.h" #include "vchiq_debugfs.h" #include "vchiq_connected.h" #include "vchiq_pagelist.h" @@ -1870,9 +1872,17 @@ static int __init vchiq_driver_init(void) { int ret; + ret = bus_register(&vchiq_bus_type); + if (ret) { + pr_err("Failed to register %s\n", vchiq_bus_type.name); + return ret; + } + ret = platform_driver_register(&vchiq_driver); - if (ret) + if (ret) { pr_err("Failed to register vchiq driver\n"); + bus_unregister(&vchiq_bus_type); + } return ret; } @@ -1880,6 +1890,7 @@ module_init(vchiq_driver_init); static void __exit vchiq_driver_exit(void) { + bus_unregister(&vchiq_bus_type); platform_driver_unregister(&vchiq_driver); } module_exit(vchiq_driver_exit); -- 2.40.1