From patchwork Fri Jun 16 12:16:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juerg Haefliger X-Patchwork-Id: 109084 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp1300494vqr; Fri, 16 Jun 2023 05:21:45 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7LYdwGS9Rck4Vp5HeZa5AmGteFu7YWhlbwpFhOtZGDHwqkA6BdjTlw7LVJAxIeTyQUbWBh X-Received: by 2002:a05:6a20:914b:b0:117:7ad7:d9a1 with SMTP id x11-20020a056a20914b00b001177ad7d9a1mr10273711pzc.20.1686918104770; Fri, 16 Jun 2023 05:21:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686918104; cv=none; d=google.com; s=arc-20160816; b=hUAvAP0rvDjn5Hi1g2/jnTim9cEHicEwtJuSHxXetLKbz2UtCkhs33R+gyQbUVuDI0 6HlA52TNOJKvkN3XuHpJ5cdNVt0dII5NEX9ap1U44ta9hwBlL1O1mCVd4uSujPTdTPub UH0nA4RwcnVG1A+LCM1hXnjT31oiMgGlC/1SfsoQ4X8PqcBv591XWYmVqP7G+oDKLQbI 2v9/3bXP/CdjLZNCYnfu/4gW9DjrlTlXBqsXo9lBWTfRjkEewne2le4UmQogzwpw+h6W so1RhSaD+r0SCbTxFPfj/Cj4BC8IbHYpGSJXci5QKNtHc7KWS8FiulbRXHXqNqpTqTtd yqBw== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=9khctnS3KGbhQfn/AhXw2BywtkyBNp99eLHZVmIExRI=; b=TDFhCfKw9J0oWHS94eLAc1/di7oaJdEbw0Qpbbljgz6evfvr59gFKQ8gdcBZe9hbrp 7IkgO8SstmWuQwQddkLekeGr9dTGbLHKJR2PPCBr5h90xsApGDOhfPRnl/kcUP3z/Kwj Nqon1paJn1wjIpsQZ6RX5TjqRNkASr0mSLKzuUk1nc/4TiiE7jiW5tbWxR3e2BAkVRgz 6Hjd6tYeJumDcfdx12sIAtVSrLJglAId6jyboq0YOg7n9wBanz0TBlvq2YiUWjPIC0pa Qjb1ENz9YQ2br2pcHtUTUI8U+UDWEgki5c4pPwx0hCm3jKVHkVYSq/oTqEvV/FsLUIR/ VRjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@canonical.com header.s=20210705 header.b=j9WX8ngB; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f10-20020a63de0a000000b0054402b987eesi14656738pgg.213.2023.06.16.05.21.30; Fri, 16 Jun 2023 05:21:44 -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 header.i=@canonical.com header.s=20210705 header.b=j9WX8ngB; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231332AbjFPMQp (ORCPT + 99 others); Fri, 16 Jun 2023 08:16:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56264 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229468AbjFPMQn (ORCPT ); Fri, 16 Jun 2023 08:16:43 -0400 Received: from smtp-relay-internal-0.canonical.com (smtp-relay-internal-0.canonical.com [185.125.188.122]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5F3C5294C for ; Fri, 16 Jun 2023 05:16:42 -0700 (PDT) Received: from mail-lf1-f72.google.com (mail-lf1-f72.google.com [209.85.167.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-0.canonical.com (Postfix) with ESMTPS id C23443F10B for ; Fri, 16 Jun 2023 12:16:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1686917800; bh=9khctnS3KGbhQfn/AhXw2BywtkyBNp99eLHZVmIExRI=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=j9WX8ngBKzxgqvog7gCOfDs0/xjxvE3/xqvK/Gx8pE2yz5Ou4qqZtHQm3H+O+4S1Z H2A/9237Mx9VOVjLcKujtFc5o47mQoUKs4han0Vsryk8Acqsqyn6TRUsefyqceP0kV ZPvo5aKP5aLCVANt4kTe3RcmKe03TbXzTwzvUfG3jAiqRz2Lmpn78J7sFu7SRrFN7I WUOzX82zXoZtTOYSVDMAa7N2s6ddpg24WQZqDwkmRoioCOaZjhK98TYsgtF5F17Z3G u02jHXhhrgfhwOtRz/9DxSX7EE68gXREHqpBq2QXvQj533Zfyndv0Wk26l8cAXXVKF bL7NNhnRajJ9w== Received: by mail-lf1-f72.google.com with SMTP id 2adb3069b0e04-4f658076c93so501232e87.0 for ; Fri, 16 Jun 2023 05:16:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686917799; x=1689509799; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=9khctnS3KGbhQfn/AhXw2BywtkyBNp99eLHZVmIExRI=; b=J8dgnLSS0zBiFcI32TNXJIm5H8B/7jDlMUTa69bF3d9CCvX33j7NESZKbGxELczUJO spUXmZ/Se7BPGZc7mLYRFXPcSrUsOEspH5UNbOavnPz2/iSlHiMyuJRGH2amxP5uPUSN ShsCiRauQKzJkDt/9w2D4vbETx8sBGzT+J5pdTnyRU/e3ei+WaLMaHzYqtZUlwk8vA7d nPhxnrgCt7lVg0F+A48OTORQCTdEfArwMppS0KMQEjFRekQswO5Ou0xelZopXEB4SQZz Rr/Mu3K0mTkhh4L+TJTrCYOinOJOVfx+h4bY7pR5/H95DZc6CUEy6CXeLWdxDO/eiIal 2gCw== X-Gm-Message-State: AC+VfDwQFH3jAsrr0xvruzVjzHJ3KnJgDp/nWfZT1GAb+MNcJebvrcdR w/G9ssJhO7/zTW95V+H3ej8gd45UpsOuOIQNHaUavv2UsAhXAz2UBJy6T5bJGS0olACDzh8001e RF0uv8sHANPDbw/FWPh7waEzgSFPmWscfde2qejqXsQ== X-Received: by 2002:a2e:90c5:0:b0:2af:23c0:ffe2 with SMTP id o5-20020a2e90c5000000b002af23c0ffe2mr1600560ljg.48.1686917799486; Fri, 16 Jun 2023 05:16:39 -0700 (PDT) X-Received: by 2002:a2e:90c5:0:b0:2af:23c0:ffe2 with SMTP id o5-20020a2e90c5000000b002af23c0ffe2mr1600543ljg.48.1686917799207; Fri, 16 Jun 2023 05:16:39 -0700 (PDT) Received: from localhost ([194.191.244.86]) by smtp.gmail.com with ESMTPSA id f20-20020a7bcc14000000b003f8044b3436sm2033492wmh.23.2023.06.16.05.16.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Jun 2023 05:16:38 -0700 (PDT) From: Juerg Haefliger To: ogabbay@kernel.org, dri-devel@lists.freedesktop.org Cc: linux-kernel@vger.kernel.org, talcohen@habana.ai, osharabi@habana.ai, dliberman@habana.ai, dhirschfeld@habana.ai, Juerg Haefliger Subject: [PATCH] habanalabs/gaudi: Add MODULE_FIRMWARE macros Date: Fri, 16 Jun 2023 14:16:37 +0200 Message-Id: <20230616121637.1033074-1-juerg.haefliger@canonical.com> X-Mailer: git-send-email 2.37.2 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,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: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768861838653403857?= X-GMAIL-MSGID: =?utf-8?q?1768861838653403857?= The module loads firmware so add MODULE_FIRMWARE macros to provide that information via modinfo. Signed-off-by: Juerg Haefliger Reviewed-by: Oded Gabbay --- drivers/accel/habanalabs/gaudi/gaudi.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/accel/habanalabs/gaudi/gaudi.c b/drivers/accel/habanalabs/gaudi/gaudi.c index a29aa8f7b6f3..cd034e98128a 100644 --- a/drivers/accel/habanalabs/gaudi/gaudi.c +++ b/drivers/accel/habanalabs/gaudi/gaudi.c @@ -63,6 +63,10 @@ #define GAUDI_LINUX_FW_FILE "habanalabs/gaudi/gaudi-fit.itb" #define GAUDI_TPC_FW_FILE "habanalabs/gaudi/gaudi_tpc.bin" +MODULE_FIRMWARE(GAUDI_BOOT_FIT_FILE); +MODULE_FIRMWARE(GAUDI_LINUX_FW_FILE); +MODULE_FIRMWARE(GAUDI_TPC_FW_FILE); + #define GAUDI_DMA_POOL_BLK_SIZE 0x100 /* 256 bytes */ #define GAUDI_RESET_TIMEOUT_MSEC 2000 /* 2000ms */