From patchwork Wed Jul 19 16:44:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 122741 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:c923:0:b0:3e4:2afc:c1 with SMTP id j3csp2579540vqt; Wed, 19 Jul 2023 10:05:04 -0700 (PDT) X-Google-Smtp-Source: APBJJlE0ljiI3+PsSgNv1+J7wF02Z5zCqI8obycTP5+LEHdmVDcDyotN39EZ5xPTqCROJ8cR9upp X-Received: by 2002:a54:4808:0:b0:3a3:7228:8c98 with SMTP id j8-20020a544808000000b003a372288c98mr6558634oij.2.1689786304553; Wed, 19 Jul 2023 10:05:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689786304; cv=none; d=google.com; s=arc-20160816; b=muzQamwKLhQTWKNHCpvfjBGH+6Yjhlmppk5LtneDvPi+sSYmqkDwz67jBoEkKPOnks vIPBzDmAidHRG7IgW7CozmxUHkPWM42VSJ6yJqmXfVNqKs4xArHe4sQpecQrTldbof2Q R3fXBpa4n+5C4qRwmJXIM0ioZ+RC6vW4wa3Z/k3kD6DLHSLDKDsEWSLWmBc0L3Wx5x9f fO9DgLTGaS1prXSBbQulJqhgaEPA9dTX2fqSrThUog4CoZ1GY9yWWmBfZzTIq+1Heha5 zClBEsJWSXbIHyp4ikH11TNKJSRvPO1hcglVVQ/mZqp33rhrrWSV04nPdcRkdRr5EGTn uwcg== 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=2RYi+ajkHRDrsRT5kpWJ/D6NmMm5EFru7k3NdoNcjPI=; fh=HOFam38REw6BIxvQyXL0jcX3gf57D0OJSEWCuf65U0M=; b=hDf+JLdnohPDpluGMWlTFuidoV9uQpu8cJx+7keiddV2RzYLgdedg6Zh+0Z0/F/v8C gUb1NuaOWzHYknXNARESpPs/pHgvFco1Ad0eX0LmGq/SQNoSGLaNnsK69beFNpDqs54I 3pRWxe9w/MeN06tPWzSRbZ0sGNKEkez/2KOXGRQC6ppxkSqntawtsj1Pjagbrjvu9Iu5 M7SqXKyCp9ZOGE9BQuVxD8Uba1NlUBZxvRWccy1t+ScRNMS8jqk902SfDTUy665bQCz8 /0HxDzWgcIDlWkNuxn0heOecbdBgeZPXkLfDPBE1W/u/LmTMR4Mha4XNVE7uVmh/RA8z qhXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=CGuoBiIE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x11-20020a17090ab00b00b002635100d850si1618295pjq.178.2023.07.19.10.04.48; Wed, 19 Jul 2023 10:05:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=CGuoBiIE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230319AbjGSQpF (ORCPT + 99 others); Wed, 19 Jul 2023 12:45:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60594 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230282AbjGSQpB (ORCPT ); Wed, 19 Jul 2023 12:45:01 -0400 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 38A721FD2; Wed, 19 Jul 2023 09:44:57 -0700 (PDT) Received: from umang.jainideasonboard.com (unknown [103.86.18.219]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 9A7DA10FF; Wed, 19 Jul 2023 18:43:50 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1689785034; bh=LeLvy8dmB49ivCc3FmszLDCbTglhyeqRh8+wWDv2694=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CGuoBiIE4MMFCAuPr8E/hhUnomzAVazDINXKnNBOSlK8nef5ve0WYt9+RswVEklx+ jItQQLj17iHf1Dn2nSPCcjRsW8wwlgCZ6WdFC9yfBH1bCrvvERrp5Tb98ouarj9Sbb yAqXcbW8x1cc/Fq/mmg0WwvkVlVvguqUhBDvCRYA= From: Umang Jain To: linux-staging@lists.linux.dev, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Cc: stefan.wahren@i2se.com, gregkh@linuxfoundation.org, f.fainelli@gmail.com, athierry@redhat.com, error27@gmail.com, dave.stevenson@raspberrypi.com, kieran.bingham@ideasonboard.com, laurent.pinchart@ideasonboard.com, Umang Jain Subject: [PATCH v9 2/5] staging: vc04_services: vchiq_arm: Register vchiq_bus_type Date: Wed, 19 Jul 2023 22:14:24 +0530 Message-Id: <20230719164427.1383646-3-umang.jain@ideasonboard.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230719164427.1383646-1-umang.jain@ideasonboard.com> References: <20230719164427.1383646-1-umang.jain@ideasonboard.com> MIME-Version: 1.0 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, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771869363934894847 X-GMAIL-MSGID: 1771869363934894847 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 | 9 +++++++++ 1 file changed, 9 insertions(+) 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..e8d40f891449 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 @@ -34,6 +35,7 @@ #include "vchiq_ioctl.h" #include "vchiq_arm.h" #include "vchiq_debugfs.h" +#include "vchiq_device.h" #include "vchiq_connected.h" #include "vchiq_pagelist.h" @@ -1870,6 +1872,12 @@ 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) pr_err("Failed to register vchiq driver\n"); @@ -1880,6 +1888,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);