From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 09:57:45 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6ABDDDF9 for ; Mon, 8 Sep 2014 09:57:45 +0000 (UTC) Received: from mail.made4.biz (mail.made4.biz [IPv6:2001:41d0:2:c018::1:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2EC7412AD for ; Mon, 8 Sep 2014 09:57:45 +0000 (UTC) Received: from 2a02-8428-011b-e000-0290-f5ff-fe9d-b78c.rev.sfr.net ([2a02:8428:11b:e000:290:f5ff:fe9d:b78c] helo=magellan.dumbbell.fr) by mail.made4.biz with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.83 (FreeBSD)) (envelope-from ) id 1XQvhf-00022D-Ce for freebsd-arch@FreeBSD.org; Mon, 08 Sep 2014 11:57:43 +0200 Message-ID: <540D7D91.9000104@FreeBSD.org> Date: Mon, 08 Sep 2014 11:57:37 +0200 From: =?UTF-8?B?SmVhbi1Tw6liYXN0aWVuIFDDqWRyb24=?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: freebsd-arch@FreeBSD.org Subject: Linux kernel API wrapper: using OFED's one in other drivers Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="7n62iuQcScCsmIiNsXRUACQwREFsxhBxC" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 09:57:45 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --7n62iuQcScCsmIiNsXRUACQwREFsxhBxC Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi! OFED (sys/ofed) comes with a Linux kernel API wrapper. Beside OFED itself, it's currently used in sys/dev/cxgb and sys/dev/cxgbe. I'm playing with this wrapper to add a new feature to the i915 GPU driver [1]. Don't pay attention to the current patch as this is not the final approach I have in mind. However, the idea is there: I'd like to use it in sys/dev/drm2. The benefit of using such a wrapper in the DRM drivers are obvious: 1. It greatly reduces the diff between FreeBSD code and Linux original code. 2. It speeds up the integration of new changes in FreeBSD. 3. It eases the report of bugfixes to Linux. Those arguments are true for any driver. But in this particular case, this would allow us to reduce the gap with Linux in the graphics stack area more quickly (and we deeply need that). DragonFlyBSD is already doing that. Of course, using this wrapper as it is today isn't practicle: the code is located in a driver and it's not even part of GENERIC. The proposal is to move it outside of OFED and add it to GENERIC. I don't have a patch to show yet. I'd like to get feedback first. What do you think about that? OFED maintainers, would you be ok? [1] https://wiki.freebsd.org/Graphics/Add_HW_context_support_to_i915 --=20 Jean-S=C3=A9bastien P=C3=A9dron --7n62iuQcScCsmIiNsXRUACQwREFsxhBxC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJUDX2XXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTMngAP/3FJiq/qG81azDdC8sHkgqJy X1qv3zSMAq74YwDlCUCRRbWJafLx0TKJrE2SFgzarc1iQcQ+8HPxL2OcEvMZOqrB TLMM4aApocVlJ2KeDfVma0qrU/idNbImLKQFdeduQ7tVWELYG5wAqSUPlkjZnyF0 OLu7k8LVWiRA51hR4VLPUMDFPxwEu61YzYiWx89WrGWT4RZ6rpWPfXaCEzoVDKU6 b5LtGaUE0GXkmm75wiZo5dekTSPWWudSskgV/VgF+zXWrIgcYFi6IHJkQp0oCw1U OzM7rZ+lPKBIUwpqNz6mOKIWR3V+SXK2BXmSX39aoMvdafqAo3GKzkkc5tvv5Mj4 iQ+rTM8LEDvdygzsKb6L/vw8JkYfdYeQRO6s0GUm7BkdvHp6se6Zn1gryu7o+WHy dtKy0T5JzJWFfI7uHLQZTXJnerS84SOOtThk4VnwcGxni7Q4HDYA4Z+OTxAO4Vbc ZA6m8091r+J1p82jcTDjV0o51RJkkY5qt8b+Edxs5mtq+z17dtdYcF9G55pEW6wY VKakdbzFgnSBY4kThqH7897OryI3GU0DQZbU79rsYpGG6JA1l8ntwJ5hdcZvRbLs o2WAWG8klja+eHNvvtCI96qWaTq0sM+4IxLYBttAPjlSIPPYdy84MQAvNafIJQ79 hbO5iFrElgz70xol46N0 =NlPC -----END PGP SIGNATURE----- --7n62iuQcScCsmIiNsXRUACQwREFsxhBxC--