#
# spec file for package dahdi-linux
#
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2019-2020 LISA GmbH, Bingen, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

%define origversion 3.1.0

Name:           dahdi-linux
Summary:        Digium Asterisk Hardware Device Interface driver
Version:        3.1.0
Release:        5.15.60
#Release:        18.19
Url:            http://asterisk.org/
License:        GPL-2.0
Group:          Productivity/Telephony/Utilities
#Git-Clone:     git://git.asterisk.org/dahdi/linux.git (branch: next)
Source:         http://downloads.asterisk.org/pub/telephony/dahdi-linux/%name-%origversion.tar.gz
Source3:        %name-preamble
# tarball made from http://downloads.digium.com/pub/telephony/firmware/releases/
Source4:        firmware-20150813.tar.xz

# include dahdi_hfc driver from git://git.code.sf.net/p/dahdi-hfcs/code
Source7:        dahdi-hfcs.tar.xz

Patch6:         stdbool.diff
Patch8:         dahdi-warn-on-once.diff
Patch9:         dahdi-oslec.diff
Patch10:        dahdi-slab.diff
Patch12:        0001-voicebus-wcaxx-wct4xxp-Remove-include-of-pci-aspm.h.patch
Patch13:        0002-Annotate-switch-case-fall-through.patch
Patch14:        0003-wcte13xp-Fix-unintended-fall-through-in-t13x_set_lin.patch
Patch15:        0004-Makefile-M-is-preferred-to-KBUILD_EXTMOD-for-externa.patch
Patch16:        0005-Use-proc_ops-on-kernels-5.6.patch
Patch17:        0006-wctdm24xxp-Fix-uninitialized-variable-warning.patch
Patch18:        0009-Remove-support-for-32-bit-userspace-with-64-bit-kern.patch
Patch19:        0010-Remove-checks-for-HAVE_UNLOCKED_IOCTL-for-kernel-5.9.patch
Patch20:        0011-vpmadt032-Create-.o.cmd-file-for-the-shipped-object-.patch
Patch21:        0012-Kbuild-Rename-hostprogs-y-to-hostprogs.patch
Patch22:        0001-dahdi-base.c-remove-netdev-trans_start-kerne-4.7.patch
Patch23:        0002-dahdi-base-netdev-send-frame-via-protocol-handlers-f.patch
Patch24:        0003-dahdi_config.h-Enable-CONFIG_DAHDI_NET.patch
Patch25:        0004-dahdi_config-Enable-DAHDI_DYNAMIC-DAHDI_DYNAMIC_LOC.patch
Patch26:        0007-Revert-Remove-support-for-driver-wcte11xp.patch
Patch27:        0008-adapt-te11xp-to-DAHDI-API-changes-since-its-removal.patch
Patch28:        0009-DAHDI_NET-Report-alarms-as-lost-carrier-to-net_devic.patch
Patch29:        0010-Introduce-ioctl-for-simulating-alarms-under-userspac.patch
Patch30:        0001-Fix-build-with-DAHDI_NET-on-kernel-5.15.patch
Patch31:        0001-Add-Osmocom-icE1usb-driver.patch
Patch32:        0001-Revert-Remove-support-for-driver-wcte12xp.patch
Patch33:        0002-adapt-te12xp-to-DAHDI-API-changes-since-its-removal.patch
Patch34:        0003-wcte12xp-Add-missing-break-statment.patch
Patch35:        0001-Build-with-support-for-CONFIG_DAHDI_MIRROR.patch
Patch36:        0001-Build-with-support-for-CONFIG_DAHDI_PPP.patch
Patch37:        0001-icE1usb-Fix-span-re-configuration-after-first-start.patch
Patch38:        0002-icE1usb-update-ice1usb_proto.h-to-current-master.patch
Patch39:        0003-icE1usb-Support-reporting-of-RED-alarm-via-DAHDI-inf.patch
Patch40:        0004-icE1usb-Support-TX-configuration-CRC4-on-off-loopbac.patch
Patch41:        0005-icE1usb-support-for-reporting-CRC-and-alignment-erro.patch
Patch42:        0006-icE1usb-Add-support-for-reporting-remote-alarm-RAI-a.patch
Patch43:        0001-wcte11xp-Fix-BLUE-AIS-alarm-detection.patch
Patch44:        99-stupid-paths.patch
#
patch45:        0001-icE1usb-Don-t-consider-altsetting-with-no-endpoints-.patch
patch46:        0002-icE1usb-raise-NOTOPEN-alarm-if-startup-fails.patch
patch47:        0003-icE1usb-Don-t-silently-ignore-startup-errors-on-re-c.patch
patch48:        0005-icE1usb-Use-USB_CTRL_SET_TIMEOUT-5s-instead-of-hand-.patch
patch49:        0008-icE1usb-update-ice1usb_proto.h-to-firmware-0.2-8.patch
patch50:        0009-icE1usb-GPSDO-status-support-in-sysfs.patch
patch51:        0013-icE1usb-avoid-system-hang-if-USB-transfer-submission.patch
#
Patch52:        0001-Fix-NULL-pointer-dereference-for-pseudo-channels.patch
Patch53:        0002-icE1usb-Fix-inverted-logic-for-clock-timing-source.patch
Patch54:        0004-Fix-Wimplicit-fallthrough-5-warnings.patch
Patch55:        0006-dahdi-sysfs-chan-Fix-potential-NULL-pointer-deref.patch
Patch56:        0001-Fix-build-against-linux-5.17.0.patch
#
Patch57:        0001-Revert-Remove-support-for-all-but-wcb41xp-wcb43xp-an.patch
Patch58:        0002-wcb4xxp-Add-support-for-Swyx-4xS0-SX2-Express-QuadBR.patch
Patch59:        0003-Revert-Remove-support-for-wctdm800-wcaex800-wctdm410.patch
#
Patch90:        dahdi-fix-leap-15.1.diff
Patch91:        dahdi-disable-xpp.patch
BuildRequires:  fdupes
#BuildRequires:  kernel-syms >= 2.6.17
#BuildRequires:  modutils
BuildRequires:  udev
BuildRequires:  xz
Provides:       dahdi = %version-%release
Obsoletes:      dahdi < %version-%release

# EC2 and UM have no PCI, but DAHDI is all about PCI device drivers
%kernel_module_package -p %name-preamble -x ec2 um

%description
This package contains configuration files, header files, and setup
tools needed for the zapata telephony interface drivers.

See %_datadir/doc/packages/dahdi/README for a list of supported
hardware.

%package KMP
Summary:        Digium Asterisk Hardware Device Interface driver
Group:          System/Kernel

%description KMP
This package contains the kernel modules of the Zapata Telephony
Interface. For details see the dahdi package.

%package devel
Summary:        Development files for the Digium Asterisk Hardware Device Interface
Group:          Development/Libraries/Other
License:	GPL-2.0 and LGPL-2.1
Requires:       %name = %version-%release
Provides:       dahdi-devel = %version-%release
Provides:       dahdi-linux-syms = %version-%release

%description devel
This package contains the header files and libraries necessary for
developing applications which use zaptel.

Install dahdi-devel if you want to develop applications which depend on
asterisk.

%prep
%setup -qa4 -n%name-%origversion
%patch -p1 -P 6 -P 8 -P 9 -P 10 -P 12 -P 13 -P 14 -P 15 -P 16 -P 17 -P 18 -P 19
%patch -p1 -P 20 -P 21 -P 22 -P 23 -P 24 -P 25 -P 26 -P 27 -P 28 -P 29 -P 30
%patch -p1 -P 31 -p 1 -P 32 -P 33 -P 34 -P 35 -P 36 -P 37 -P 38 -P 39 -P 40
%patch -p1 -P 41 -P 42 -P 43 -P 44 -P 45 -P 46 -P 47 -P 48 -P 49 -P 50
%patch -p1 -P 51 -P 52 -P 53 -P 54 -P 55 -P 56 -P 57 -P 58 -P 59
%if 0%{?sle_version} == 150100 && 0%{?is_opensuse}
%patch -p1 -P 90
%endif
%if %__isa_bits == 32
%patch -p1 -P 91
%endif
pushd drivers/dahdi/firmware/
for i in *.tar*; do
	tar -xf "$i"
done
popd

# prepare dahdi_hfcs module
tar xf %{S:7}

%build
export CFLAGS="%optflags"
export MODULES_EXTRA="dahdi_dummy"
rm -rf ../obj
mkdir -p ../obj
for flavor in %flavors_to_build; do
	cp -a . "../obj/$flavor"
	pushd "../obj/$flavor"
	%make_build KSRC="/usr/src/linux-obj/%_target_cpu/$flavor" \
	DAHDI_MODULES_EXTRA='hfcs/'
	popd
done

%install
export MODULES_EXTRA="dahdi_dummy"
b="%buildroot"
for flavor in %flavors_to_build; do
	pushd "../obj/$flavor"
	%make_install INSTALL_MOD_PATH="$b" \
		KSRC="/usr/src/linux-obj/%_target_cpu/$flavor" \
		DAHDI_MODULES_EXTRA='hfcs/'

	# wanpipe-kmp wants this
	dahdi_dir="%_includedir/dahdi/obj/%_target_cpu/$flavor"
	mkdir -p "$b/$dahdi_dir"
	cp -a include "$b/$dahdi_dir/"
	ln -s "%_includedir/dahdi" "$b/$dahdi_dir/include/dahdi"
	mkdir -p "$b/$dahdi_dir/drivers/dahdi"
	cp -a drivers/dahdi/Module*.symvers "$b/$dahdi_dir/drivers/dahdi"

	# wanted by voicesync/wanpipe-voicetime
	cp -a drivers/dahdi/ecdis.h "$b/$dahdi_dir/drivers/dahdi"
	cp -a drivers/dahdi/biquad.h "$b/$dahdi_dir/drivers/dahdi"
	echo "%version" >"$b/$dahdi_dir/.version"

	popd
done

# remove pointless double copy
rm -Rfv "$b/usr/lib/hotplug"
%fdupes %buildroot/%_prefix

%files
%license LICENSE*
%doc README
/lib/firmware/*
/lib/firmware/.dahdi*
%_datadir/dahdi/

%files devel
%_includedir/dahdi/

%changelog
* Sun May  1 2022 Martin Hauke <mardnh@gmx.de>
- (re-)add support for older cards
  * 0001-Revert-Remove-support-for-all-but-wcb41xp-wcb43xp-an.patch
  * 0002-wcb4xxp-Add-support-for-Swyx-4xS0-SX2-Express-QuadBR.patch
  * 0003-Revert-Remove-support-for-wctdm800-wcaex800-wctdm410.patch
- Add support for Swyx-4xS0-SX2-Express-QuadBRI
  * 0002-wcb4xxp-Add-support-for-Swyx-4xS0-SX2-Express-QuadBR.patch
* Fri Apr 29 2022 Martin Hauke <mardnh@gmx.de>
- Add some patches
  * 0001-Fix-NULL-pointer-dereference-for-pseudo-channels.patch
  * 0002-icE1usb-Fix-inverted-logic-for-clock-timing-source.patch
  * 0004-Fix-Wimplicit-fallthrough-5-warnings.patch
  * 0006-dahdi-sysfs-chan-Fix-potential-NULL-pointer-deref.patch
  * 0001-Fix-build-against-linux-5.17.0.patch
* Mon Mar 14 2022 Martin Hauke <mardnh@gmx.de>
- More osmocom icE1usb improvements:
  * 0001-icE1usb-Don-t-consider-altsetting-with-no-endpoints-.patch
  * 0002-icE1usb-raise-NOTOPEN-alarm-if-startup-fails.patch
  * 0003-icE1usb-Don-t-silently-ignore-startup-errors-on-re-c.patch
  * 0005-icE1usb-Use-USB_CTRL_SET_TIMEOUT-5s-instead-of-hand-.patch
  * 0008-icE1usb-update-ice1usb_proto.h-to-firmware-0.2-8.patch
  * 0009-icE1usb-GPSDO-status-support-in-sysfs.patch
  * 0013-icE1usb-avoid-system-hang-if-USB-transfer-submission.patch
* Wed Jan 19 2022 Jan Engelhardt <jengelh@inai.de>
- Add stdbool.diff
- Modify 0001-Revert-Remove-support-for-driver-wcte12xp.patch
  to not use stdbool.h anymore.
* Mon Jan  3 2022 Martin Hauke <mardnh@gmx.de>
- Osmocom icE1usb improvements:
  * 0001-icE1usb-Fix-span-re-configuration-after-first-start.patch
  * 0002-icE1usb-update-ice1usb_proto.h-to-current-master.patch
  * 0003-icE1usb-Support-reporting-of-RED-alarm-via-DAHDI-inf.patch
  * 0004-icE1usb-Support-TX-configuration-CRC4-on-off-loopbac.patch
  * 0005-icE1usb-support-for-reporting-CRC-and-alignment-erro.patch
  * 0006-icE1usb-Add-support-for-reporting-remote-alarm-RAI-a.patch
- Fix BLUE alarm dection for wcte11xp
  * 0001-wcte11xp-Fix-BLUE-AIS-alarm-detection.patch
* Tue Dec  7 2021 Martin Hauke <mardnh@gmx.de>
- Add patch
  * 0001-Build-with-support-for-CONFIG_DAHDI_PPP.patch
* Mon Dec  6 2021 Martin Hauke <mardnh@gmx.de>
- Add patch
  * 0001-Build-with-support-for-CONFIG_DAHDI_MIRROR.patch
* Mon Nov 29 2021 Martin Hauke <mardnh@gmx.de>
- Add Support for osmocom icE1usb
  * 0001-Add-Osmocom-icE1usb-driver.patch
- Readd wcte12xp driver (those cards still working fine !)
  * 0001-Revert-Remove-support-for-driver-wcte12xp.patch
  * 0002-adapt-te12xp-to-DAHDI-API-changes-since-its-removal.patch
  * 0003-wcte12xp-Add-missing-break-statment.patch
* Mon Nov 29 2021 Martin Hauke <mardnh@gmx.de>
- Add patch:
  * 0001-Fix-build-with-DAHDI_NET-on-kernel-5.15.patch
* Wed May  5 2021 Jan Engelhardt <jengelh@inai.de>
- Move modules back to their standard paths to have
  ksym() symbols generated.
* Sat Jan 16 2021 Martin Hauke <mardnh@gmx.de>
- Set MODULES_EXTRA="dahdi_dummy" to build the dahdi_dummy driver.
* Fri Dec 25 2020 Martin Hauke <mardnh@gmx.de>
- Disable XPP on 32bit systems (compilation errors)
  * dahdi-disable-xpp.patch
* Tue Dec 15 2020 Martin Hauke <mardnh@gmx.de>
- Add some patches from https://github.com/osmocom/dahdi-linux
- Enable CONFIG_DAHDI_NET
  * 0003-dahdi_config.h-Enable-CONFIG_DAHDI_NET.patch
  * 0001-dahdi-base.c-remove-netdev-trans_start-kerne-4.7.patch
- Enable DAHDI_DYNAMIC and DAHDI_DYNAMIC_LOC
  * 0004-dahdi_config-Enable-DAHDI_DYNAMIC-DAHDI_DYNAMIC_LOC.patch
- Readd wcte11xp driver (those cards still working fine !)
  * 0007-Revert-Remove-support-for-driver-wcte11xp.patch
  * 0008-adapt-te11xp-to-DAHDI-API-changes-since-its-removal.patch
- Fix HDLC encapsulation, netdev: send frame via protocol handlers
  * 0002-dahdi-base-netdev-send-frame-via-protocol-handlers-f.patch
- DAHDI_NET: Report alarms as lost carrier to net_device
  * 0009-DAHDI_NET-Report-alarms-as-lost-carrier-to-net_devic.patch
- Introduce ioctl() for simulating alarms under userspace control
  * 0010-Introduce-ioctl-for-simulating-alarms-under-userspac.patch
* Tue Dec 15 2020 Martin Hauke <mardnh@gmx.de>
- Add patches to fix builds with Kernel >= 5.9 and gcc >= 10
  * 0001-voicebus-wcaxx-wct4xxp-Remove-include-of-pci-aspm.h.patch
  * 0002-Annotate-switch-case-fall-through.patch
  * 0003-wcte13xp-Fix-unintended-fall-through-in-t13x_set_lin.patch
  * 0004-Makefile-M-is-preferred-to-KBUILD_EXTMOD-for-externa.patch
  * 0005-Use-proc_ops-on-kernels-5.6.patch
  * 0006-wctdm24xxp-Fix-uninitialized-variable-warning.patch
  * 0009-Remove-support-for-32-bit-userspace-with-64-bit-kern.patch
  * 0010-Remove-checks-for-HAVE_UNLOCKED_IOCTL-for-kernel-5.9.patch
  * 0011-vpmadt032-Create-.o.cmd-file-for-the-shipped-object-.patch
  * 0012-Kbuild-Rename-hostprogs-y-to-hostprogs.patch
- Drop not longer needed patches
  * dahdi-pmake.diff
  * dahdi-moddir.diff
  * dahdi-fix-kernel-5.4.diff
* Sun Sep  6 2020 Jan Engelhardt <jengelh@inai.de>
- Update to release 3.1.0
* Thu Feb  6 2020 Hans-Peter Jansen <hpj@urpla.net>
- Add patch to fix build with Kernel >= 5.4.0: dahdi-fix-kernel-5.4.diff
* Thu Jul 25 2019 Hans-Peter Jansen <hpj@urpla.net>
- Update to 3.1.0-rc1 in order to build with kernel >= 5.0
- Apply dahdi-fix-leap-15.1.diff for Leap 15.1 kernels
  Funfact: timer_setup was backported, but definition of
  TIMER_DATA_TYPE, as being used from its callback, not adjusted
  accordingly...
* Tue Jan  8 2019 Jan Engelhardt <jengelh@inai.de>
- Update to new upstream release 3.0.0
  * Removed drivers wcte12xp, wcte11xp, wct1xxp, wcb4xxp drivers.
    Cards affected: TE120P, TE121, TE122, TE110P, T100P, E100P,
    B410, Tormenta.
- Drop 0001-signal_pending-is-now-in-linux-sched-signal.h-includ.patch,
  0002-atomic_read-refcount_read.patch (merged),
  dahdi-kill-xpp_h.diff (obsolete)
* Mon Sep  4 2017 jengelh@inai.de
- Add 0001-signal_pending-is-now-in-linux-sched-signal.h-includ.patch,
  0002-atomic_read-refcount_read.patch.
* Wed Mar 30 2016 jengelh@inai.de
- Update to new upstream release 2.11.1
* Fri Jan 22 2016 jengelh@inai.de
- Update to new upstream release 2.11.0
* Thu Aug 13 2015 jengelh@inai.de
- Update to new upstream release 2.10.2
* Mon Mar 16 2015 jengelh@inai.de
- Update to new upstream release 2.10.1
* Thu Nov 20 2014 joop.boonen@opensuse.org
- Added a slab include patch to build the package for armv7l
* Mon Oct 13 2014 jengelh@inai.de
- Update to new upstream release 2.10.0.1
  * Set no_read, no_write methods for devices
* Fri Aug 22 2014 jengelh@inai.de
- Update to new upstream release 2.10.0
  * Support for Linux 3.17
- Reenable OSLEC echo canceller module again
- Update firmwares to 20140822:
  * te436 was added
* Tue May 27 2014 jengelh@inai.de
- Update to new upstream release 2.9.1
- Update firmwares to 20140527
* Wed Feb 26 2014 joop.boonen@opensuse.org
- Update to new upstream release 2.9.0
* Fri Dec 27 2013 jengelh@inai.de
- Install all header files
* Tue Dec 24 2013 jengelh@inai.de
- Update to new upstream release 2.8.0.1
  * No upstream changelog was provided
* Thu Oct  3 2013 jengelh@inai.de
- Update to new upstream release 2.7.0.1
  * No upstream changelog was provided
* Thu Aug 15 2013 jengelh@inai.de
- Update to new upstream release 2.7.0
  * Support for Linux 3.10
  * Support for te133, te134, vpmoct032
* Thu Jan 24 2013 jengelh@inai.de
- Add package signature verification
- Kernels older than 2.6.17 are in fact no longer supported, so
  remove SLES10 patch
* Mon Aug 27 2012 jamesp@vicidial.com
- Added extra header files needed by third party drivers to compile
- Added obsoletes for older 'dahdi' packages
* Mon Jun 25 2012 jengelh@inai.de
- Update to new upstream release 2.6.1
  * support for Linux 3.4
  * misc crash and race fixes on unload
* Sun Feb  5 2012 chris@computersalat.de
- update to 2.6.0
  * a lot of changes, please see the ChangeLog file for more info
* Thu Dec 15 2011 jengelh@medozas.de
- Update to new upstream release 2.6.0-rc1, changelog is at
  http://downloads.asterisk.org/pub/telephony/dahdi-linux/ChangeLog-2.6.0-rc1
* Mon Oct 31 2011 jengelh@medozas.de
- Ship Module.symvers for use by "wanpipe" package
* Mon Oct 17 2011 jengelh@medozas.de
- Add patch to add missing WARN_ON_ONCE define to wctdm24xxp for
  kernels < 2.6.18
* Tue Oct  4 2011 jengelh@medozas.de
- Update to new upstream release 2.5.0.1, for changelog see
  http://downloads.asterisk.org/pub/telephony/dahdi-linux/ChangeLog-2.5.0.1
- Update to firmware-20111005 (2.5.0.1 depends on it),
  and reduce its size by removing redundant files in the archive.
- Remove redundant/unwanted tags/sections (cf. specfile guidelines)
- Remove duplicate copy of firmware files
- Put building commands into %%build, not %%install;
  replace convoluted installation by single-shot installation
- Enable parallel make
- Build for all kernel flavors
- Exclude EC2 flavor due to lack of PCI which DAHDI requires
- Set the minimum kernel version required (currently: 2.6.18-rc1
  due to use of WARN_ON_ONCE in source code)
- Add Provides: dahdi/dahdi-devel to cater for BuildRequires of
  other packages
- Avoid compiling echo.ko again, allows to drop kernel-source
- dahdi-linux should not require KMP (gives "have choice"), rather,
  KMPs should Require dahdi-linux (for firmware)
* Tue Apr 12 2011 chris@computersalat.de
- update to 2.4.1.2
  * include/dahdi/kernel.h: dahdi: Do not define dev_name if already
    backported. RHEL 5.6 has backported dev_name in
    include/dahdi/devices.h. We now need to check for a back ported
    definition before defining our own version on pre 2.6.26 kernels.
    (closes issue #18992) Reported by: ndupeux, AlexCeli Tested by:
    elguero Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com>
    Acked-by: Shaun Ruffell <sruffell@digium.com> Origin:
    http://svnview.digium.com/svn/dahdi?view=rev&rev=9894
  * wctdm24xxp: Fix regression with LEDS on TDM410.
- remove Author from Description
* Tue Mar  8 2011 chris@computersalat.de
- update to 2.4.1
  * build_tools/make_version: make_version: Use 'git rev-parse' if
    only looking for a sha5. Different versions of git have
    variability in how the log output looks. Instead of git log, we
    can use git rev-parse directly. Signed-off-by: Shaun Ruffell
    <sruffell@digium.com> Origin:
    http://svnview.digium.com/svn/dahdi?view=rev&rev=9475
  * build_tools/make_version: make_version: svn and git metadata
    directory not checked properly. (closes issue #16143) Reported
    by: Max Khon Signed-off-by: Kinsey Moore <kmoore@digium.com>
    Signed-off-by: Shaun Ruffell <sruffell@digium.com> Origin:
    http://svnview.digium.com/svn/dahdi?view=rev&rev=9418
  * build_tools/make_version: make_version: '[[' -> '[' since it's
    not a bash script. '[[' is a bash construct specifically, yet
    [#]!/bin/sh is at the top of the file. Signed-off-by: Shaun Ruffell
    <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com>
    Acked-by: Russ Meyerriecks <rmeyerriecks@digium.com> Acked-by:
    Tzafrir Cohen <tzafrir.cohen@xorcom.com> Review:
    https://reviewboard.asterisk.org/r/940/ Origin:
    http://svnview.digium.com/svn/dahdi?view=rev&rev=9408
  * Makefile, build_tools/make_version: dahdi: Generate
    include/dahdi/version.h when building in a git repository. If
    building within a git repository search the last log message for
    a 'git-svn-id'. If found, the commit has a corresponding svn
    revision number and we will use the SVN-xxx-rxxx revision form.
    Otherwise use the output of 'git describe --long --always --tags
  - -dirty=M' as the version. Signed-off-by: Shaun Ruffell
    <sruffell@digium.com> Acked-by: Tzafrir Cohen
    <tzafrir.cohen@xorcom.com> Origin:
    http://svnview.digium.com/svn/dahdi?view=rev&rev=9396
  - for further changes please see ChangeLog file
* Sat Nov  6 2010 chris@computersalat.de
- spec cleanup
  o macros
* Fri Nov  5 2010 toganm@opensuse.org
- enable echo_oslec for opensuse >11.1 more info regarding oslec is at
  http://www.rowetel.com/blog/?page_id=454
* Thu Nov  4 2010 chris@computersalat.de
- update to 2.4.0
  o lot of changes please see ChangeLog file
- reworked firmware
  o added dahdi-fwload-vpmadt032-1.25.0.tar.gz
* Wed Jun 16 2010 chris@computersalat.de
- fix build for Factory (11.3)
- removed obsolete patches
  o dahdi, rtc, kzalloc
* Tue Jun 15 2010 chris@computersalat.de
- update to 2.3.0.1
  * drivers/dahdi/voicebus/GpakCust.h, /,
    drivers/dahdi/voicebus/GpakApi.c,
    drivers/dahdi/voicebus/voicebus.c,
    drivers/dahdi/voicebus/GpakCust.c: Merged revisions
    8560,8575-8576 via svnmerge from
    https://origsvn.digium.com/svn/dahdi/linux/trunk ........ r8560 |
    sruffell | 2010-04-22 16:36:16 -0500 (Thu, 22 Apr 2010) | 11
    lines wcte12xp, wctdm24xxp: Ensure writes to I/O registers are
    flushed. In revision 8176 I changed register access from I/O
    space to memory mapped registers. Unfortunately, when I made that
    change, I didn't account for posted writes. This change makes
    sure all the registers are read back to ensure that they are
    posted through any intermediate bridges. The most readily
    observable symptom were cards that were taking 2000
    interrupts/second. The card reported that it handled an interrupt
    but the write to silence the card wasn't flushed through until
    the second time the interrupt handler run. DAHDI-602. ........
    r8575 | sruffell | 2010-04-26 18:29:16 -0500 (Mon, 26 Apr 2010) |
    4 lines wcte12xp, wctdm24xxp: Do not allow interruptible sleep on
    VPM lock. If the sleep is ever interrupted, 'up' will still be
    called in the GpakApi, essentially making the lock useless after
    that point. ........ r8576 | sruffell | 2010-04-26 18:29:17 -0500
    (Mon, 26 Apr 2010) | 9 lines wcte12xp, wctdm24xxp: Retry if the
    VPMADT032 reports not ready. CheckDspReset can return -1 if the
    DSP is not ready to process any new commands. In this case we
    should retry a few times to give the DSP a chance to become
    ready. While I'm not ready to say this definitely fixes recently
    reported cases when the wcte12xp driver constantly resets, it
    eliminated communication failures to the DSP module when under
    stress (via the vpm_firmware_version sysfs attribute). However, I
    haven't let it run long enough to say that the issue is resolved.
    DAHDI-603. ........
  * /, drivers/dahdi/dahdi_echocan_jpah.c: missing #include: fixes
    building with 2.6.34-rc5 With kernel 2.6.34-rc5 an explicit
    '#include <slab.h>' is required for using kzalloc() and friends.
    Merged revisions 8550 via svnmerge from
    http://svn.digium.com/svn/dahdi/linux/trunk
  * drivers/dahdi/xpp/xpp_debug, /, drivers/dahdi/xpp/card_pri.c,
    drivers/dahdi/wcb4xxp/Makefile, drivers/dahdi/xpp/card_bri.c,
    drivers/dahdi/xpp/card_global.c, drivers/dahdi/dahdi-base.c:
    typos, mostly unkown Merged revisions 8539 via svnmerge from
    http://svn.digium.com/svn/dahdi/linux/trunk
  * Makefile, /: Remove generation of kernel-doc API docs It's not
    really useful, and it breaks building 'docs' without a kernel
    tree. Merged revisions 8538 via svnmerge from
    http://svn.digium.com/svn/dahdi/linux/trunk
  * /: initialize svnmerge
* Thu Apr 22 2010 chris@computersalat.de
- fix build for kernel > 2.6.34
  o added kzalloc patch
* Wed Apr 21 2010 chris@computersalat.de
- update to 2.3.0
  * lot of changes see ChangeLog
- updated firmware
- remove obsolete patches
  * dahdi-linux-2.2.1.1-autoconf_h.patch
  * dahdi-driver.patch
* Sat Mar 27 2010 chris@computersalat.de
- update to 2.2.1.1
  * wct4xxp: Added support for for qfalc v3.1 framer.
  * wct4xxp: Added ID tags for generation 5 firmware updates
- added autoconf.h patch
  o fix build for kernel > 2.6.31
    autoconf.h moved from linux/ to generated
- rpmlint
  o fixed group for devel pkg Development/Libraries/Other
- clenup spec
* Fri Jan 22 2010 chris@computersalat.de
- update to 2.2.1
  * dahdi-linux version 2.2.1 released.
  * drivers/dahdi/xpp/xbus-pcm.c, /: xpp: demote a message that
    generates some false alarms. Merged revisions 7843 via svnmerge
    from http://svn.digium.com/svn/dahdi/linux/trunk
  * /, drivers/dahdi/xpp/firmwares/USB_FW.hex: xpp: USB_FW rev 7578
    Fixes various minor twinstar-related bugs. Merged revisions 7815
    via svnmerge from http://svn.digium.com/svn/dahdi/linux/trunk
  * drivers/dahdi/xpp/xbus-pcm.c, /: xpp: fixes for drift
    calculation. Should help for the case of multiple quad-PRI
    Astribanks on a single system. xpp rev: 7666. Merged revisions
    7807 via svnmerge from
    http://svn.digium.com/svn/dahdi/linux/trunk
  * drivers/dahdi/xpp/xbus-pcm.c, /, drivers/dahdi/xpp/xbus-pcm.h,
    drivers/dahdi/xpp/xbus-sysfs.c: xpp: Improved inter-Astribank
    drift calculation. Merged revisions 7625 via svnmerge from
    http://svn.digium.com/svn/dahdi/linux/trunk
  * drivers/dahdi/dahdi-base.c: dahdi-base: change
    dahdi_kernel_fpu_end to kernel_fpu_end dahdi_kernel_fpu_end is
    part of the MMX changes in trunk that was not committed into the
    2.2 branch. This change snuck in as part of revision 6864 with
    the master span processing changes.
  * voicebus, wcte12xp: Only define SLAB_STORE_USER when CONFIG_SLUB
    is defined. On 2.6.22, there is was a bug in the SLUB allocator
    that required defining SLAB_STORE_USER, however this setting is
    only valid when CONFIG_SLUB is defined and not when using the
    previous slab allocator. DAHDI-424.
- added ChangeLog, LICENSE*, README to doc
* Thu Jan 14 2010 chris@computersalat.de
- include actual tarball version in package version
- cleanup source
  o updated tarball to its upstream version
  * it is an rc release
* Sat Jan  9 2010 chris@computersalat.de
- fix build-/deps
- moved changelog to changes file
- removed pre/-un post/-un
* Mon Jan  4 2010 chris@computersalat.de
- cleanup spec
  o added header
  o sort TAGS
  o fix deps
  o some rpmlint stuff
- cleanup source
  o added .changes file
- kernel modules to "updates"
* Mon Dec 21 2009 vittorio@vitsoft.bz
- dahdi-linux 2.2.1
* Wed Aug 19 2009 vittorio@vitsoft.bz
- dahdi-linux 2.2.0.2
* Fri Jul  3 2009 vittorio@vitsoft.bz
- dahdi-linux 2.2.0.1
* Wed Jul  1 2009 vittorio@vitsoft.bz
- dahdi-linux 2.2.0
* Wed Dec 10 2008 vittorio@vitsoft.bz
- dahdi-linux 2.1.0
* Sat Oct  4 2008 vittorio@vitsoft.bz
- dahdi-linux 2.0.0
* Mon Sep 15 2008 vittorio@vitsoft.bz
- dahdi-linux 2.0.0 rc4