rpms/pcmciautils/F-7 pcmciautils-014-funcname.patch, NONE, 1.1 pcmciautils-014-newrules.patch, 1.2, 1.3 pcmciautils.spec, 1.24, 1.25
Harald Hoyer (harald)
fedora-extras-commits at redhat.com
Thu Jun 21 09:29:11 UTC 2007
Author: harald
Update of /cvs/pkgs/rpms/pcmciautils/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv28595
Modified Files:
pcmciautils-014-newrules.patch pcmciautils.spec
Added Files:
pcmciautils-014-funcname.patch
Log Message:
- fixed modprobe udev rule
- fixed 'pccardctl ident' SEGV
- Resolves: rhbz#242805
pcmciautils-014-funcname.patch:
--- NEW FILE pcmciautils-014-funcname.patch ---
--- pcmciautils-014/src/pccardctl.c~ 2006-06-01 10:07:52.000000000 +0100
+++ pcmciautils-014/src/pccardctl.c 2007-06-05 22:20:36.000000000 +0100
@@ -37,6 +37,7 @@ static char *fn[] = {
"AIMS",
"SCSI"
};
+#define NR_FNS ( sizeof(fn) / sizeof(*fn) )
/* crc32hash.c - derived from linux/lib/crc32.c, GNU GPL v2 */
static unsigned int crc32(unsigned char const *p, unsigned int len)
@@ -219,7 +220,7 @@ static int pccardctl_ident(unsigned long
char *prod_id[4];
int valid_prod_id = 0;
int i;
- unsigned int manf_id, card_id;
+ unsigned int manf_id, card_id, func_id;
if (!pccardctl_socket_exists(socket_no))
return -ENODEV;
@@ -249,9 +250,15 @@ static int pccardctl_ident(unsigned long
if (!pccardctl_get_one(socket_no, "card_id", &card_id))
printf(" manfid: 0x%04x, 0x%04x\n", manf_id, card_id);
- if (!pccardctl_get_one(socket_no, "func_id", &manf_id))
- printf(" function: %d (%s)\n", manf_id, fn[manf_id]);
+ if (!pccardctl_get_one(socket_no, "func_id", &func_id)) {
+ char *func_name;
+ if (func_id < NR_FNS)
+ func_name = fn[func_id];
+ else
+ func_name = "unknown";
+ printf(" function: 0x%x (%s), %d\n", func_id, func_name, NR_FNS);
+ }
return 0;
}
pcmciautils-014-newrules.patch:
Index: pcmciautils-014-newrules.patch
===================================================================
RCS file: /cvs/pkgs/rpms/pcmciautils/F-7/pcmciautils-014-newrules.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- pcmciautils-014-newrules.patch 19 Jun 2006 07:13:25 -0000 1.2
+++ pcmciautils-014-newrules.patch 21 Jun 2007 09:29:02 -0000 1.3
@@ -1,5 +1,14 @@
---- pcmciautils-014/udev/rules-base.newrules 2006-06-19 09:12:29.000000000 +0200
-+++ pcmciautils-014/udev/rules-base 2006-06-19 09:12:58.000000000 +0200
+--- pcmciautils-014/udev/rules-modprobe.newrule 2006-06-01 11:07:52.000000000 +0200
++++ pcmciautils-014/udev/rules-modprobe 2007-06-21 11:13:14.000000000 +0200
+@@ -1,3 +1,4 @@
++### Already done by the general modprobe rule
+ # modprobe $modalias loads all possibly appropriate modules
+-ACTION=="add", SUBSYSTEM=="pcmcia", MODALIAS=="?*", \
+- RUN+="/sbin/modprobe $modalias"
++#ACTION=="add", SUBSYSTEM=="pcmcia", ENV{MODALIAS}=="?*", \
++# RUN+="/sbin/modprobe $env{MODALIAS}"
+--- pcmciautils-014/udev/rules-base.newrule 2006-06-01 11:07:52.000000000 +0200
++++ pcmciautils-014/udev/rules-base 2007-06-21 11:13:02.000000000 +0200
@@ -3,12 +3,12 @@
# are so broken that we need to read out random bytes of it
# instead of the manufactor, card or product ID. Then the
@@ -15,10 +24,3 @@
RUN+="/bin/sh -c 'echo 1 > /sys/$devpath/allow_func_id_match'"
# PCMCIA sockets:
---- pcmciautils-014/udev/rules-modprobe.newrules 2006-06-19 09:12:38.000000000 +0200
-+++ pcmciautils-014/udev/rules-modprobe 2006-06-19 09:13:12.000000000 +0200
-@@ -1,3 +1,3 @@
- # modprobe $modalias loads all possibly appropriate modules
--ACTION=="add", SUBSYSTEM=="pcmcia", MODALIAS=="?*", \
-+ACTION=="add", SUBSYSTEM=="pcmcia", ENV{MODALIAS}=="?*", \
- RUN+="/sbin/modprobe $modalias"
Index: pcmciautils.spec
===================================================================
RCS file: /cvs/pkgs/rpms/pcmciautils/F-7/pcmciautils.spec,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- pcmciautils.spec 2 Apr 2007 10:01:56 -0000 1.24
+++ pcmciautils.spec 21 Jun 2007 09:29:02 -0000 1.25
@@ -2,7 +2,7 @@
Summary: PCMCIA utilities and initialization programs
License: GPL
Version: 014
-Release: 7%{?dist}
+Release: 9%{?dist}
Group: System Environment/Base
ExclusiveArch: i386 x86_64 ia64 ppc ppc64
URL: http://www.kernel.org/pub/linux/utils/kernel/pcmcia/pcmcia.html
@@ -18,6 +18,7 @@
BuildRequires: byacc, flex
Patch1: pcmciautils-fedora.patch
Patch2: pcmciautils-014-newrules.patch
+Patch3: pcmciautils-014-funcname.patch
%description
The pcmciautils package contains utilities for initializing and
@@ -27,7 +28,8 @@
%setup -q
# Fix build peculiarities
%patch1 -p1
-%patch2 -p1
+%patch2 -p1 -b .newrule
+%patch3 -p1
%build
make %{?_smp_mflags}
@@ -52,6 +54,13 @@
%{_mandir}/man*/pccardctl*
%changelog
+* Thu Jun 21 2007 Harald Hoyer <harald at redhat.com> - 014-9
+- fixed modprobe udev rule
+
+* Wed Jun 6 2007 Harald Hoyer <harald at redhat.com> - 014-8
+- fixed 'pccardctl ident' SEGV
+- Resolves: rhbz#242805
+
* Mon Apr 2 2007 Harald Hoyer <harald at redhat.com> - 014-7
- removed Provides, because it would conflict (#234504)
- Resolves: rhbz#234504
More information about the fedora-extras-commits
mailing list