rpms/libraw1394/F-10 libraw1394-2.0.0-fix-channel_modify.patch, NONE, 1.1 libraw1394.spec, 1.47, 1.48
Jarod Wilson
jwilson at fedoraproject.org
Fri Dec 5 19:29:10 UTC 2008
Author: jwilson
Update of /cvs/pkgs/rpms/libraw1394/F-10
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv12141
Modified Files:
libraw1394.spec
Added Files:
libraw1394-2.0.0-fix-channel_modify.patch
Log Message:
* Fri Dec 05 2008 Jarod Wilson <jarod at redhat.com> - 2.0.0-4
- Fix channel modify code, should make iso reception work reliably now
libraw1394-2.0.0-fix-channel_modify.patch:
--- NEW FILE libraw1394-2.0.0-fix-channel_modify.patch ---
diff -Naurp libraw1394-2.0.0.orig/src/dispatch.c libraw1394-2.0.0.fix/src/dispatch.c
--- libraw1394-2.0.0.orig/src/dispatch.c 2008-12-05 11:37:36.686557198 -0500
+++ libraw1394-2.0.0.fix/src/dispatch.c 2008-12-05 11:38:57.117432534 -0500
@@ -553,10 +553,7 @@ int raw1394_channel_modify (raw1394handl
errno = EINVAL;
return -1;
}
- if (handle->is_fw)
- return fw_channel_modify(handle, channel, mode);
- else
- return ieee1394_channel_modify(handle, channel, mode);
+ return ieee1394_channel_modify(handle, channel, mode);
}
int raw1394_iso_xmit_init(raw1394handle_t handle,
diff -Naurp libraw1394-2.0.0.orig/src/fw.c libraw1394-2.0.0.fix/src/fw.c
--- libraw1394-2.0.0.orig/src/fw.c 2008-12-05 11:37:36.689432892 -0500
+++ libraw1394-2.0.0.fix/src/fw.c 2008-12-05 11:39:44.830509943 -0500
@@ -1342,52 +1342,3 @@ fw_bandwidth_modify (raw1394handle_t han
return 0;
}
-
-int
-fw_channel_modify (raw1394handle_t handle,
- unsigned int channel,
- enum raw1394_modify_mode mode)
-{
- quadlet_t buffer, compare, swap, bit;
- nodeaddr_t addr;
- int result;
-
- if (channel >= 64)
- return -1;
- addr = CSR_REGISTER_BASE +
- CSR_CHANNELS_AVAILABLE_HI + 4 * (channel / 32);
- /* Read currently available channels from IRM. */
- result = raw1394_read(handle, raw1394_get_irm_id (handle), addr,
- sizeof buffer, &buffer);
- if (result < 0)
- return -1;
-
- /* IEEE numbers bits from MSB (0) to LSB (31). */
- bit = 1 << (31 - (channel & 31));
- compare = ntohl(buffer);
- switch (mode) {
- case RAW1394_MODIFY_ALLOC:
- if ((compare & bit) == 0)
- return -1;
- swap = buffer & ~bit;
- break;
-
- case RAW1394_MODIFY_FREE:
- if ((buffer & bit) != 0)
- return -1;
- swap = buffer | bit;
- break;
-
- default:
- return -1;
- }
-
- result = raw1394_lock (handle, raw1394_get_irm_id (handle), addr,
- RAW1394_EXTCODE_COMPARE_SWAP,
- htonl(swap), htonl(compare), &buffer);
-
- if (result < 0 || ntohl(buffer) != compare)
- return -1;
-
- return 0;
-}
diff -Naurp libraw1394-2.0.0.orig/src/fw.h libraw1394-2.0.0.fix/src/fw.h
--- libraw1394-2.0.0.orig/src/fw.h 2008-07-05 16:16:30.000000000 -0400
+++ libraw1394-2.0.0.fix/src/fw.h 2008-12-05 11:40:02.062495475 -0500
@@ -214,9 +214,6 @@ int fw_get_config_rom(fw_handle_t handle
int fw_bandwidth_modify (raw1394handle_t handle,
unsigned int bandwidth,
enum raw1394_modify_mode mode);
-int fw_channel_modify (raw1394handle_t handle,
- unsigned int channel,
- enum raw1394_modify_mode mode);
int fw_iso_xmit_start(raw1394handle_t handle, int start_on_cycle,
int prebuffer_packets);
diff -Naurp libraw1394-2.0.0.orig/src/raw1394.h libraw1394-2.0.0.fix/src/raw1394.h
--- libraw1394-2.0.0.orig/src/raw1394.h 2008-07-06 15:03:31.000000000 -0400
+++ libraw1394-2.0.0.fix/src/raw1394.h 2008-12-05 11:39:23.582432381 -0500
@@ -1203,7 +1203,7 @@ raw1394_bandwidth_modify (raw1394handle_
enum raw1394_modify_mode mode);
/**
- * raw1394_bandwidth_modify - allocate or release isochronous channel
+ * raw1394_channel_modify - allocate or release isochronous channel
* @handle: a libraw1394 handle
* @channel: isochronous channel
* @mode: whether to allocate or free
Index: libraw1394.spec
===================================================================
RCS file: /cvs/pkgs/rpms/libraw1394/F-10/libraw1394.spec,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -r1.47 -r1.48
--- libraw1394.spec 20 Nov 2008 17:52:48 -0000 1.47
+++ libraw1394.spec 5 Dec 2008 19:28:40 -0000 1.48
@@ -1,12 +1,13 @@
Summary: Library providing low-level IEEE-1394 access
Name: libraw1394
Version: 2.0.0
-Release: 3%{?dist}
+Release: 4%{?dist}
License: LGPLv2+
Group: System Environment/Libraries
Source: http://www.linux1394.org/dl/libraw1394-%{version}.tar.gz
Patch0: libraw1394-2.0.0-coverity-prevent-fixes.patch
Patch1: libraw1394-2.0.0-git-fixes.patch
+Patch2: libraw1394-2.0.0-fix-channel_modify.patch
URL: http://www.linux1394.org/
ExcludeArch: s390 s390x
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -31,6 +32,7 @@
%setup -q
%patch0 -p1
%patch1 -p1
+%patch2 -p1
%build
%configure --disable-static
@@ -69,6 +71,9 @@
%changelog
+* Fri Dec 05 2008 Jarod Wilson <jarod at redhat.com> - 2.0.0-4
+- Fix channel modify code, should make iso reception work reliably now
+
* Thu Nov 20 2008 Jarod Wilson <jarod at redhat.com> - 2.0.0-3
- Address some compiler warnings
- Reduce nesting depth in new_handle dispatches
More information about the fedora-extras-commits
mailing list