Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Aug 2013 08:47:41 GMT
From:      Alexander  <Alexander.Klishin@billing.ru>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   misc/181135: sys/dev/netmap patch for Linux compatibility
Message-ID:  <201308080847.r788lfgf043714@oldred.freebsd.org>
Resent-Message-ID: <201308080850.r788o0X1029641@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         181135
>Category:       misc
>Synopsis:       sys/dev/netmap patch for Linux compatibility
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Thu Aug 08 08:50:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Alexander
>Release:        
>Organization:
www.billing.ru
>Environment:
>Description:
Linux contain more precise way to locate lock free version of "ioctl" function.

Current implementation is based on kernel version, and does not detect proper "ioctl" version on old kernels (RedHat 6.3, kernel 2.6.32).

Patch is attached.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

--- netmap/sys/dev/netmap/netmap.c	2013-08-07 13:17:25.000000000 +0400
+++ netmap.ioctl/sys/dev/netmap/netmap.c	2013-08-08 12:39:05.939206484 +0400
@@ -2027,7 +2027,7 @@
 }
 
 
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)	// XXX was 38
+#if !defined(HAVE_UNLOCKED_IOCTL)
 #define LIN_IOCTL_NAME	.ioctl
 int
 linux_netmap_ioctl(struct inode *inode, struct file *file, u_int cmd, u_long data /* arg */)


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201308080847.r788lfgf043714>