[arch-commits] Commit in fcpci/trunk (PKGBUILD fcpci.install kernel-2.6.34.patch)
Tobias Powalowski
tpowa at archlinux.org
Mon May 17 18:08:22 UTC 2010
Date: Monday, May 17, 2010 @ 14:08:21
Author: tpowa
Revision: 80487
upgpkg: fcpci 31107-53
rebuild against latest kernel
Added:
fcpci/trunk/kernel-2.6.34.patch
Modified:
fcpci/trunk/PKGBUILD
fcpci/trunk/fcpci.install
---------------------+
PKGBUILD | 36 ++++++----
fcpci.install | 4 -
kernel-2.6.34.patch | 170 ++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 195 insertions(+), 15 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2010-05-17 17:43:34 UTC (rev 80486)
+++ PKGBUILD 2010-05-17 18:08:21 UTC (rev 80487)
@@ -3,37 +3,47 @@
pkgname=fcpci
pkgver=31107
-pkgrel=52
-_kernver=2.6.33-ARCH
+pkgrel=53
+_kernver=2.6.34-ARCH
pkgdesc="AVM ISDN driver for FRITZ PCI isdn cards. For stock arch 2.6 kernel."
arch=(i686 x86_64)
license=('custom:"AVM"' 'LGPL')
url="http://www.avm.de"
-depends=('capi4k-utils' 'kernel26>=2.6.33' 'kernel26<2.6.34')
-makedepends=('kernel26-headers>=2.6.33' 'kernel26-headers<2.6.34')
+depends=('capi4k-utils' 'kernel26>=2.6.34' 'kernel26<2.6.35')
+makedepends=('kernel26-headers>=2.6.34' 'kernel26-headers<2.6.35')
if [ "$CARCH" = "i686" ]; then
- source=(ftp://ftp.avm.de/cardware/fritzcrd.pci/linux/suse.93/fcpci-suse93-3.11-07.tar.gz \
- kernel-2.6.19.patch atomic.patch kernel-2.6.20.patch kernel-2.6.22.patch \
- kernel-2.6.24.patch kernel-2.6.31.patch)
+ source=(ftp://ftp.avm.de/cardware/fritzcrd.pci/linux/suse.93/fcpci-suse93-3.11-07.tar.gz
+ kernel-2.6.19.patch
+ atomic.patch kernel-2.6.20.patch
+ kernel-2.6.22.patch
+ kernel-2.6.24.patch
+ kernel-2.6.31.patch
+ kernel-2.6.34.patch)
md5sums=('3ee301b5d0e8df9e4b915af58b725556'
'5c63dc9df0810bb1ba85f3425abaa0ed'
'258b13bb2ac46960b9c91635f02cd080'
'890ec6e1219a3a4bae77f5815c3ed40d'
'4f4f03630ed994b16b4cd167f090a116'
'21bfa466b1fb94663ed1f265948dba5e'
- '34f5b78b219de8ce12793b16e0171e87')
+ '34f5b78b219de8ce12793b16e0171e87'
+ '224a7679645a51929f8d5e1f210d7a9e')
+
fi
if [ "$CARCH" = "x86_64" ]; then
- source=(ftp://ftp.avm.de/cardware/fritzcrd.pci/linux_64bit/suse.10.0/fcpci-suse10.0-64bit-3.11-07.tar.gz \
- kernel-2.6.19.patch atomic.patch kernel-2.6.20.patch kernel-2.6.22.patch \
- kernel-2.6.24.patch kernel-2.6.31.patch)
+ source=(ftp://ftp.avm.de/cardware/fritzcrd.pci/linux_64bit/suse.10.0/fcpci-suse10.0-64bit-3.11-07.tar.gz
+ kernel-2.6.19.patch
+ atomic.patch kernel-2.6.20.patch kernel-2.6.22.patch
+ kernel-2.6.24.patch
+ kernel-2.6.31.patch
+ kernel-2.6.34.patch)
md5sums=('c5595478515d19436ab20b42e1549de0'
'5c63dc9df0810bb1ba85f3425abaa0ed'
'258b13bb2ac46960b9c91635f02cd080'
'890ec6e1219a3a4bae77f5815c3ed40d'
'4f4f03630ed994b16b4cd167f090a116'
'21bfa466b1fb94663ed1f265948dba5e'
- '34f5b78b219de8ce12793b16e0171e87')
+ '34f5b78b219de8ce12793b16e0171e87'
+ '224a7679645a51929f8d5e1f210d7a9e')
fi
install=fcpci.install
@@ -45,6 +55,7 @@
patch -Np0 -i ../../kernel-2.6.22.patch || return 1
patch -Np0 -i ../../kernel-2.6.24.patch || return 1
patch -Np0 -i ../../kernel-2.6.31.patch || return 1
+ patch -Np0 -i ../../kernel-2.6.34.patch || return 1
cd ..
# fix from Karsten Keil <kkeil at suse.de>
# in refernece to bug: http://bugs.archlinux.org/task/8511
@@ -71,4 +82,3 @@
# build module dependencies
sed -i -e "s/KERNEL_VERSION=.*/KERNEL_VERSION=${_kernver}/g" $startdir/fcpci.install
}
-
Modified: fcpci.install
===================================================================
--- fcpci.install 2010-05-17 17:43:34 UTC (rev 80486)
+++ fcpci.install 2010-05-17 18:08:21 UTC (rev 80487)
@@ -7,7 +7,7 @@
sed -i -e 's/#fcpci - - - - - -/fcpci - - - - - -/g' /etc/capi.conf
# updating module dependencies
echo ">>> Updating module dependencies. Please wait ..."
- KERNEL_VERSION=2.6.33-ARCH
+ KERNEL_VERSION=2.6.34-ARCH
depmod -v $KERNEL_VERSION > /dev/null 2>&1
}
@@ -22,7 +22,7 @@
sed -i -e 's/fcpci - - - - - -/#fcpci - - - - - -/g' /etc/capi.conf
# updating module dependencies
echo ">>> Updating module dependencies. Please wait ..."
- KERNEL_VERSION=2.6.33-ARCH
+ KERNEL_VERSION=2.6.34-ARCH
depmod -v $KERNEL_VERSION > /dev/null 2>&1
}
Added: kernel-2.6.34.patch
===================================================================
--- kernel-2.6.34.patch (rev 0)
+++ kernel-2.6.34.patch 2010-05-17 18:08:21 UTC (rev 80487)
@@ -0,0 +1,170 @@
+--- driver.c~ 2010-05-17 11:51:30.315940940 +0200
++++ driver.c 2010-05-17 11:51:30.362264370 +0200
+@@ -48,6 +48,8 @@
+ #include "defs.h"
+ #include "lib.h"
+ #include "driver.h"
++#include <linux/proc_fs.h>
++#include <linux/seq_file.h>
+
+ /*---------------------------------------------------------------------------*\
+ \*---------------------------------------------------------------------------*/
+@@ -490,39 +492,34 @@
+
+ /*---------------------------------------------------------------------------*\
+ \*---------------------------------------------------------------------------*/
+-static int __kcapi ctr_info (
+- char * page,
+- char ** start,
+- off_t ofs,
+- int count,
+- int * eof,
+- struct capi_ctr * ctrl
++
++static int __kcapi ctr_info (struct seq_file *m, void *v
+ ) {
++ struct capi_ctr *ctrl = m->private;
+ card_t * card;
+ char * temp;
+ unsigned char flag;
+- int len = 0;
+
+ assert (ctrl != NULL);
+ card = (card_t *) ctrl->driverdata;
+ assert (card != NULL);
+- pprintf (page, &len, "%-16s %s\n", "name", SHORT_LOGO);
+- pprintf (page, &len, "%-16s 0x%04x\n", "io", card->base);
+- pprintf (page, &len, "%-16s %d\n", "irq", card->irq);
++ seq_printf(m, "%-16s %s\n", "name", SHORT_LOGO);
++ seq_printf(m, "%-16s 0x%04x\n", "io", card->base);
++ seq_printf(m, "%-16s %d\n", "irq", card->irq);
+ temp = card->version ? card->string[1] : "A1";
+- pprintf (page, &len, "%-16s %s\n", "type", temp);
++ seq_printf(m, "%-16s %s\n", "type", temp);
+ temp = card->version ? card->string[0] : "-";
+ #if defined (__fcclassic__) || defined (__fcpcmcia__)
+- pprintf (page, &len, "%-16s 0x%04x\n", "revision", card->info);
++ seq_printf(m, "%-16s 0x%04x\n", "revision", card->info);
+ #elif defined (__fcpci__)
+- pprintf (page, &len, "%-16s %d\n", "class", card_id);
++ seq_printf(m, "%-16s %d\n", "class", card_id);
+ #endif
+- pprintf (page, &len, "%-16s %s\n", "ver_driver", temp);
+- pprintf (page, &len, "%-16s %s\n", "ver_cardtype", SHORT_LOGO);
++ seq_printf(m, "%-16s %s\n", "ver_driver", temp);
++ seq_printf(m, "%-16s %s\n", "ver_cardtype", SHORT_LOGO);
+
+ flag = ((unsigned char *) (ctrl->profile.manu))[3];
+ if (flag) {
+- pprintf(page, &len, "%-16s%s%s%s%s%s%s%s\n", "protocol",
++ seq_printf(m, "%-16s%s%s%s%s%s%s%s\n", "protocol",
+ (flag & 0x01) ? " DSS1" : "",
+ (flag & 0x02) ? " CT1" : "",
+ (flag & 0x04) ? " VN3" : "",
+@@ -534,21 +531,30 @@
+ }
+ flag = ((unsigned char *) (ctrl->profile.manu))[5];
+ if (flag) {
+- pprintf(page, &len, "%-16s%s%s%s%s\n", "linetype",
++ seq_printf(m, "%-16s%s%s%s%s\n", "linetype",
+ (flag & 0x01) ? " point to point" : "",
+ (flag & 0x02) ? " point to multipoint" : "",
+ (flag & 0x08) ? " leased line without D-channel" : "",
+ (flag & 0x04) ? " leased line with D-channel" : ""
+ );
+ }
+- if (len < ofs) {
+- return 0;
+- }
+- *eof = 1;
+- *start = page - ofs;
+- return ((count < len - ofs) ? count : len - ofs);
++
++ return 0;
+ } /* ctr_info */
+
++static int ctr_proc_open(struct inode *inode, struct file *file)
++{
++ return single_open(file, ctr_info, PDE(inode)->data);
++}
++
++const struct file_operations ctr_proc_fops = {
++ .owner = THIS_MODULE,
++ .open = ctr_proc_open,
++ .read = seq_read,
++ .llseek = seq_lseek,
++ .release = single_release,
++};
++
+ /*---------------------------------------------------------------------------*\
+ \*---------------------------------------------------------------------------*/
+ static void __kcapi reset_ctrl (struct capi_ctr * ctrl) {
+--- driver.c~ 2010-05-17 19:55:09.158499792 +0200
++++ driver.c 2010-05-17 19:55:09.190784099 +0200
+@@ -222,16 +222,6 @@
+ } /* kill_version */
+
+ /*---------------------------------------------------------------------------*\
+-\*---------------------------------------------------------------------------*/
+-static void pprintf (char * page, int * len, const char * fmt, ...) {
+- va_list args;
+-
+- va_start (args, fmt);
+- *len += vsprintf (page + *len, fmt, args);
+- va_end (args);
+-} /* pprintf */
+-
+-/*---------------------------------------------------------------------------*\
+ \*-C-------------------------------------------------------------------------*/
+ static inline int in_critical (void) {
+
+@@ -632,7 +622,7 @@
+ ctrl->release_appl = release_appl;
+ ctrl->send_message = send_msg;
+ ctrl->procinfo = proc_info;
+- ctrl->ctr_read_proc = ctr_info;
++ ctrl->proc_fops = &ctr_proc_fops;
+ if (0 != (res = attach_capi_ctr (ctrl))) {
+ dec_use_count ();
+ stop (card);
+--- driver.c~ 2010-05-17 19:57:16.935038735 +0200
++++ driver.c 2010-05-17 19:57:16.997010852 +0200
+@@ -109,7 +109,7 @@
+ /*---------------------------------------------------------------------------*\
+ \*---------------------------------------------------------------------------*/
+ static void scheduler (unsigned long data);
+-static irqreturn_t irq_handler (int irq, void * args, struct pt_regs * regs);
++static irqreturn_t irq_handler (int irq, void * args);
+
+ static DECLARE_TASKLET_DISABLED (scheduler_tasklet, scheduler, 0);
+
+@@ -832,7 +832,7 @@
+
+ /*---------------------------------------------------------------------------*\
+ \*---------------------------------------------------------------------------*/
+-static irqreturn_t irq_handler (int irq, void * args, struct pt_regs * regs) {
++static irqreturn_t irq_handler (int irq, void * args) {
+ int res = IRQ_NONE;
+
+ UNUSED_ARG (irq);
+--- driver.c~ 2010-05-17 20:00:05.071747956 +0200
++++ driver.c 2010-05-17 20:00:05.130307573 +0200
+@@ -836,7 +836,6 @@
+ int res = IRQ_NONE;
+
+ UNUSED_ARG (irq);
+- UNUSED_ARG (regs);
+ if (args != NULL) {
+ assert (capi_lib->cm_handle_events != NULL);
+ if (atomic_read (&scheduler_id) == smp_processor_id ()) {
+--- driver.c~ 2010-05-17 20:03:10.224528922 +0200
++++ driver.c 2010-05-17 20:03:10.273706462 +0200
+@@ -196,7 +196,7 @@
+ }
+ lib_strncpy (ctrl->serial, tmp, CAPI_SERIAL_LEN);
+ lib_memcpy (&ctrl->profile, card->string[6], sizeof (capi_profile));
+- strncpy (ctrl->manu, "AVM GmbH", CAPI_MANUFACTURER_LEN);
++ lib_strncpy (ctrl->manu, "AVM GmbH", CAPI_MANUFACTURER_LEN);
+ ctrl->version.majorversion = 2;
+ ctrl->version.minorversion = 0;
+ tmp = card->string[0];
More information about the arch-commits
mailing list