Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp3633488rwb; Tue, 8 Nov 2022 06:48:24 -0800 (PST) X-Google-Smtp-Source: AA0mqf5w42UvR7BgFQ9CVKpcy7mjcyJxYdodNlU8eBFOW88FLJLzI+7KJPU5BVe8mw0tIiFmZwZA X-Received: by 2002:a50:fc95:0:b0:466:63a3:386b with SMTP id f21-20020a50fc95000000b0046663a3386bmr10815466edq.241.1667918904449; Tue, 08 Nov 2022 06:48:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1667918904; cv=none; d=google.com; s=arc-20160816; b=oTATUpyuB6p6qTOguYvwtMTdudA5foHzHU1jAzKB48jo+e4Houn+eyGH5zDalQ3Yjk g2wsd6an5xx2Rqudb1ldkVlf7vB5y9VxD0KC1SvOQSIBNcM2uiojj/5X2e0cxI4vHJrj PRZxCCqoC6v8wtlNUUgIOFda87ny6K1uTh++96dd4XWC0xlSlWCnVtDKf8Wj0EcoPogy IzHhX4OCBlZCbaonbb/1rlipFPEgKGFThnk3/hKS664qCM+aKk+Q7Q57LFHMrVjBMW0B zOkEzDI+Inf5ta1DbgwYyVDpF7EMlgGLcv09+FWYmVHxc/DPS/8DUQLa/RtVyCBp0sRb bahQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=/C+b508gAj/Q+BmeIpxPFXFveLDZojLGt927GrLKC/s=; b=vQsf0DSVXYdOShxT/hKyyxpFKFvmGfgngykdYhdycBKzTVm0CIw7XHO0vARRrXkxnQ a12qIPfW8euuqGbjgMMjxdzIf2ZaogFsj4+8fxS7txGcIiWyXvIp3NdyFvVcyG5cv9JA 8zkxZvZOKOF/JpvPsdtLr5YCm8dMv7W+yj1weAz+SZJpHAcfv88iBT61drSX1HvT2kHz oFQXQFuJqK8P8DPNCs4HvjrghKoyFe5SKPFBCGv/BHmRj+492bc+EAkBsF13qsMZegIB ztWuNM5p3kIjmWLLJLF2v+c/vQC3HoHxQ7ZvJHgwOx2P/z8BGWtkzoFJ0QGl5fHcF+dL h+yQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=T5XI5kDa; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a8-20020a1709064a4800b007ae1723e8d7si10071623ejv.610.2022.11.08.06.48.03; Tue, 08 Nov 2022 06:48:24 -0800 (PST) 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=@kernel.org header.s=k20201202 header.b=T5XI5kDa; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234230AbiKHMs6 (ORCPT + 89 others); Tue, 8 Nov 2022 07:48:58 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34726 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234278AbiKHMst (ORCPT ); Tue, 8 Nov 2022 07:48:49 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B14F81928B for ; Tue, 8 Nov 2022 04:48:46 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0FA3061522 for ; Tue, 8 Nov 2022 12:48:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 78680C4314F for ; Tue, 8 Nov 2022 12:48:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1667911725; bh=/C+b508gAj/Q+BmeIpxPFXFveLDZojLGt927GrLKC/s=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=T5XI5kDaxuWTZFlRoTxCxMjci3972mvKPT1Js/gWkB4QwmGvSLR9AwDBnJK2CZOvs BpwvKvfXohfo44tUC4z7BDUfwN7o/4TG2+sVrKWmcuAssZ9lKqCVJTMJdTMqsBN8Sw jSEBWQHBJJN221ZCDrWEAH3SAdopIIwNkZiQCFH7V19QjvVfWMXoNAH2fPCkgQUIOf OqmjawYaRAToWUNGQg0XyvXtMeYb8HWpxyCKY8T7jOZqBbrSTA8VG31nARZqhIThup yxF/ydBFHmxSrqHbX9W7ihHn/V+TW6EfUq7F0sL8CLT8hWGDrL2mb+nCpOPobmUnVi s3wtUuAIC5eBw== Received: by mail-yb1-f174.google.com with SMTP id n85so11619892yba.1 for ; Tue, 08 Nov 2022 04:48:45 -0800 (PST) X-Gm-Message-State: ANoB5pllAJAXpAYrAGHsrfSS27+SSIuxgR6ibImSLCXdPZo4tiMyP2Oc pY6oyyLRN5pfYydGTJHpKTA0hY/ZO1LdF5PLhHg= X-Received: by 2002:a25:2389:0:b0:6d8:7f81:edaf with SMTP id j131-20020a252389000000b006d87f81edafmr7102372ybj.443.1667911724199; Tue, 08 Nov 2022 04:48:44 -0800 (PST) MIME-Version: 1.0 References: <20221106210225.2065371-1-ogabbay@kernel.org> <20221106210225.2065371-2-ogabbay@kernel.org> <20221108124614.GA6397@linux.intel.com> In-Reply-To: <20221108124614.GA6397@linux.intel.com> From: Oded Gabbay Date: Tue, 8 Nov 2022 14:48:17 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC PATCH v3 1/3] drivers/accel: define kconfig and register a new major To: Stanislaw Gruszka Cc: David Airlie , Daniel Vetter , Arnd Bergmann , Greg Kroah-Hartman , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Jason Gunthorpe , John Hubbard , Alex Deucher , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Yuji Ishikawa , Jiho Chu , Daniel Stone , Tvrtko Ursulin , Jeffrey Hugo , Christoph Hellwig , Kevin Hilman , Jagan Teki , Jacek Lawrynowicz , Maciej Kwapulinski , Randy Dunlap Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,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 On Tue, Nov 8, 2022 at 2:46 PM Stanislaw Gruszka wrote: > > On Sun, Nov 06, 2022 at 11:02:23PM +0200, Oded Gabbay wrote: > > Add a new Kconfig for the accel subsystem. The Kconfig currently > > contains only the basic CONFIG_DRM_ACCEL option that will be used to > > decide whether to compile the accel registration code. Therefore, the > > kconfig option is defined as bool. > > > > The accel code will be compiled as part of drm.ko and will be called > > directly from the DRM core code. The reason we compile it as part of > > drm.ko and not as a separate module is because of cyclic dependency > > between drm.ko and the separate module (if it would have existed). > > This is due to the fact that DRM core code calls accel functions and > > vice-versa. > > > > The accelerator devices will be exposed to the user space with a new, > > dedicated major number - 261. > > > > The accel init function registers the new major number as a char device > > and create corresponding sysfs and debugfs root entries, similar to > > what is done in DRM init function. > > > > I added a new header called drm_accel.h to include/drm/, that will hold > > the prototypes of the drm_accel.c functions. In case CONFIG_DRM_ACCEL > > is set to 'N', that header will contain empty inline implementations of > > those functions, to allow DRM core code to compile successfully > > without dependency on CONFIG_DRM_ACCEL. > > > > I Updated the MAINTAINERS file accordingly with the newly added folder > > and I have taken the liberty to appropriate the dri-devel mailing list > > and the dri-devel IRC channel for the accel subsystem. > > > > Signed-off-by: Oded Gabbay > > Tested-by: Stanislaw Gruszka > > I tested those patches with intel_vpu driver. After initial troubles, > I got things worked with our driver and user mode components. > > Regards > Stanislaw Thanks! Great to hear that. Oded