From owner-svn-src-head@freebsd.org Thu Oct 29 15:04:38 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 19EF0A218B8; Thu, 29 Oct 2015 15:04:38 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (heidi.turbocat.net [88.198.202.214]) (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 D35AB1493; Thu, 29 Oct 2015 15:04:37 +0000 (UTC) (envelope-from hps@selasky.org) Received: from laptop015.home.selasky.org (cm-176.74.213.204.customer.telag.net [176.74.213.204]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id 98C171FE023; Thu, 29 Oct 2015 16:04:28 +0100 (CET) Subject: Re: svn commit: r290003 - head/sys/ofed/include/linux To: Gleb Smirnoff References: <201510261328.t9QDSYRT076892@repo.freebsd.org> <56302F9D.2020308@freebsd.org> <56308289.4050902@selasky.org> <20151029143651.GN97830@FreeBSD.org> Cc: Julian Elischer , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org From: Hans Petter Selasky Message-ID: <563235E3.1090805@selasky.org> Date: Thu, 29 Oct 2015 16:06:11 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: <20151029143651.GN97830@FreeBSD.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Oct 2015 15:04:38 -0000 On 10/29/15 15:36, Gleb Smirnoff wrote: > H> The parameters for bus_bind_intr() are not available outside the > H> LinuxKPI. To support such a functionality we should wrap it, for the > H> sake of maintainability. > H> > H> The LinuxKPI is not a binary compatibility module, and will at some > H> point have API's diverging from Linux, to fit BSD API's better. > > This statement makes the name of LinuxKPI quite pointless, as well > as the whole idea of the KPI unclear. > > Can you please explain what is the target of LinuxKPI, then? Hi, The target of the LinuxKPI is at the moment to support building device drivers and protocol layers which share code between *BSD and Linux. The target is not to kldload a kernel object file from Linux and have it work under FreeBSD. For example when you build a PCI network driver, the PCI enumeration can be shared between Linux and FreeBSD, building only OS specific network handling on top. In the case of r290003 support is added for binding an IRQ vector to a CPU, in a way that can easily be patched into an existing driver using the LinuxKPI. When you build a cross platform Linux/FreeBSD protocol stack, handling of LIST macros, bitmaps, timers, condition variables, mutexes, threads and so on can be shared. Like the basics of modern operating systems. This is the Linux Kernel Programming Interface, LinuxKPI, in FreeBSD. If you have a better name then please speak up. --HPS