diff --git a/.cvsignore b/.cvsignore deleted file mode 100644 index d05c54f..0000000 --- a/.cvsignore +++ /dev/null @@ -1 +0,0 @@ -udev-151.tar.bz2 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6c20107 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +udev-151.tar.bz2 +udev-153.tar.bz2 +udev-153.tar.bz2.sign diff --git a/0001-set-SELinux-context-on-add-but-not-on-change-events.patch b/0001-set-SELinux-context-on-add-but-not-on-change-events.patch new file mode 100644 index 0000000..7ed88b4 --- /dev/null +++ b/0001-set-SELinux-context-on-add-but-not-on-change-events.patch @@ -0,0 +1,35 @@ +From 326c5fc3ea684825629eccaf33a548759162a539 Mon Sep 17 00:00:00 2001 +From: Kay Sievers +Date: Tue, 31 Aug 2010 21:29:21 +0200 +Subject: [PATCH] set SELinux context on 'add' but not on 'change' events + +--- + udev/udev-node.c | 9 ++++++++- + 1 files changed, 8 insertions(+), 1 deletions(-) + +diff --git a/udev/udev-node.c b/udev/udev-node.c +index 228b3eb..c8113f1 100644 +--- a/udev/udev-node.c ++++ b/udev/udev-node.c +@@ -56,10 +56,17 @@ int udev_node_mknod(struct udev_device *dev, const char *file, mode_t mode, uid_ + info(udev, "set permissions %s, %#o, uid=%u, gid=%u\n", file, mode, uid, gid); + chmod(file, mode); + chown(file, uid, gid); +- udev_selinux_lsetfilecon(udev, file, mode); + } else { + info(udev, "preserve permissions %s, %#o, uid=%u, gid=%u\n", file, mode, uid, gid); + } ++ /* ++ * Set initial selinux file context only on add events. ++ * We set the proper context on bootup (triger) or for newly ++ * added devices, but we don't change it later, in case ++ * something else has set a custom context in the meantime. ++ */ ++ if (strcmp(udev_device_get_action(dev), "add") == 0) ++ udev_selinux_lsetfilecon(udev, file, mode); + /* always update timestamp when we re-use the node, like on media change events */ + utimensat(AT_FDCWD, file, NULL, 0); + } else { +-- +1.7.2.3 + diff --git a/0017-udev-acl-properly-handle-CK-change-events-for-root-u.patch b/0017-udev-acl-properly-handle-CK-change-events-for-root-u.patch new file mode 100644 index 0000000..fc32c06 --- /dev/null +++ b/0017-udev-acl-properly-handle-CK-change-events-for-root-u.patch @@ -0,0 +1,52 @@ +From 939cc18afc49ee8479572c14c7fa777646fd4add Mon Sep 17 00:00:00 2001 +From: Kay Sievers +Date: Tue, 3 Aug 2010 15:09:46 +0200 +Subject: [PATCH 17/18] udev-acl: properly handle CK change events for root user + +mschmidt@redhat.com writes: +> since root is treated specially, it does not do anything! +> udev-acl may want to prevent removing ACLs from root, but +> it must not stop the ACLs being granted to the user of the +> new session. + +https://bugzilla.redhat.com/show_bug.cgi?id=608712 +--- + extras/udev-acl/udev-acl.c | 7 +------ + 1 files changed, 1 insertions(+), 6 deletions(-) + +diff --git a/extras/udev-acl/udev-acl.c b/extras/udev-acl/udev-acl.c +index ff04ec6..f2b5005 100644 +--- a/extras/udev-acl/udev-acl.c ++++ b/extras/udev-acl/udev-acl.c +@@ -224,14 +224,10 @@ static int consolekit_called(const char *ck_action, uid_t *uid, uid_t *uid2, con + if (s == NULL) + return -1; + u = strtoul(s, NULL, 10); +- if (u == 0) +- return 0; + s = getenv("CK_SEAT_SESSION_USER_UID"); + if (s == NULL) + return -1; + u2 = strtoul(s, NULL, 10); +- if (u2 == 0) +- return 0; + + s = getenv("CK_SEAT_OLD_SESSION_IS_LOCAL"); + s2 = getenv("CK_SEAT_SESSION_IS_LOCAL"); +@@ -263,12 +259,11 @@ static int consolekit_called(const char *ck_action, uid_t *uid, uid_t *uid2, con + a = ACTION_ADD; + u = u2; + } +- + break; + case ACTION_NONE: + break; + default: +- g_assert_not_reached (); ++ g_assert_not_reached(); + break; + } + +-- +1.7.2 + diff --git a/0018-udev-acl-really-fix-ACL-assignment-in-CK-events.patch b/0018-udev-acl-really-fix-ACL-assignment-in-CK-events.patch new file mode 100644 index 0000000..9187554 --- /dev/null +++ b/0018-udev-acl-really-fix-ACL-assignment-in-CK-events.patch @@ -0,0 +1,125 @@ +From 9ac90ae153accdfcb56c24c5748690933ad219b2 Mon Sep 17 00:00:00 2001 +From: Michal Schmidt +Date: Wed, 4 Aug 2010 11:53:25 +0200 +Subject: [PATCH 18/18] udev-acl: really fix ACL assignment in CK events + +The previous fix for udev-acl was incomplete. The ACL were not properly +assigned to the new user when switching from root's session because of +the test for 'uid != 0'. + +Centralize the special handling of root to a single place (in set_facl). + +https://bugzilla.redhat.com/show_bug.cgi?id=608712 +--- + extras/udev-acl/udev-acl.c | 37 +++++++++++++++++++------------------ + 1 files changed, 19 insertions(+), 18 deletions(-) + +diff --git a/extras/udev-acl/udev-acl.c b/extras/udev-acl/udev-acl.c +index f2b5005..31e9991 100644 +--- a/extras/udev-acl/udev-acl.c ++++ b/extras/udev-acl/udev-acl.c +@@ -12,20 +12,18 @@ + * General Public License for more details: + */ + +-#include +-#include +-#include +-#include +-#include +-#include +-#include +-#include ++#include ++#include + #include + #include +-#include + #include +-#include ++#include + #include ++#include ++#include ++#include ++#include ++#include + + static int debug; + +@@ -45,6 +43,10 @@ static int set_facl(const char* filename, uid_t uid, int add) + acl_permset_t permset; + int ret; + ++ /* don't touch ACLs for root */ ++ if (uid == 0) ++ return 0; ++ + /* read current record */ + acl = acl_get_file(filename, ACL_TYPE_ACCESS); + if (!acl) +@@ -190,8 +192,6 @@ static int consolekit_called(const char *ck_action, uid_t *uid, uid_t *uid2, con + if (s == NULL) + return -1; + u = strtoul(s, NULL, 10); +- if (u == 0) +- return 0; + + s = getenv("CK_SEAT_SESSION_IS_LOCAL"); + if (s == NULL) +@@ -205,8 +205,6 @@ static int consolekit_called(const char *ck_action, uid_t *uid, uid_t *uid2, con + if (s == NULL) + return -1; + u = strtoul(s, NULL, 10); +- if (u == 0) +- return 0; + + s = getenv("CK_SEAT_OLD_SESSION_IS_LOCAL"); + if (s == NULL) +@@ -331,6 +329,7 @@ int main (int argc, char* argv[]) + }; + int action = -1; + const char *device = NULL; ++ bool uid_given = false; + uid_t uid = 0; + uid_t uid2 = 0; + const char* remove_session_id = NULL; +@@ -357,6 +356,7 @@ int main (int argc, char* argv[]) + device = optarg; + break; + case 'u': ++ uid_given = true; + uid = strtoul(optarg, NULL, 10); + break; + case 'd': +@@ -369,8 +369,9 @@ int main (int argc, char* argv[]) + } + } + +- if (action < 0 && device == NULL && uid == 0) +- consolekit_called(argv[optind], &uid, &uid2, &remove_session_id, &action); ++ if (action < 0 && device == NULL && !uid_given) ++ if (!consolekit_called(argv[optind], &uid, &uid2, &remove_session_id, &action)) ++ uid_given = true; + + if (action < 0) { + fprintf(stderr, "missing action\n\n"); +@@ -378,13 +379,13 @@ int main (int argc, char* argv[]) + goto out; + } + +- if (device != NULL && uid != 0) { ++ if (device != NULL && uid_given) { + fprintf(stderr, "only one option, --device=DEVICEFILE or --user=UID expected\n\n"); + rc = 3; + goto out; + } + +- if (uid != 0) { ++ if (uid_given) { + switch (action) { + case ACTION_ADD: + /* Add ACL for given uid to all matching devices. */ +-- +1.7.2 + diff --git a/0034-add-LGPL-COPYING-to-libudev-and-GUdev.patch b/0034-add-LGPL-COPYING-to-libudev-and-GUdev.patch new file mode 100644 index 0000000..8440ea9 --- /dev/null +++ b/0034-add-LGPL-COPYING-to-libudev-and-GUdev.patch @@ -0,0 +1,1035 @@ +From 23325a66ccf3a2f90a4f5d1702f60408187de28a Mon Sep 17 00:00:00 2001 +From: Kay Sievers +Date: Thu, 18 Mar 2010 09:57:44 +0100 +Subject: [PATCH 34/36] add LGPL COPYING to libudev and GUdev + +--- + extras/gudev/COPYING | 504 ++++++++++++++++++++++++++++++++++++++++++++++++++ + libudev/COPYING | 504 ++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 1008 insertions(+), 0 deletions(-) + create mode 100644 extras/gudev/COPYING + create mode 100644 libudev/COPYING + +diff --git a/extras/gudev/COPYING b/extras/gudev/COPYING +new file mode 100644 +index 0000000..8add30a +--- /dev/null ++++ b/extras/gudev/COPYING +@@ -0,0 +1,504 @@ ++ GNU LESSER GENERAL PUBLIC LICENSE ++ Version 2.1, February 1999 ++ ++ Copyright (C) 1991, 1999 Free Software Foundation, Inc. ++ 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ++ Everyone is permitted to copy and distribute verbatim copies ++ of this license document, but changing it is not allowed. ++ ++[This is the first released version of the Lesser GPL. It also counts ++ as the successor of the GNU Library Public License, version 2, hence ++ the version number 2.1.] ++ ++ Preamble ++ ++ The licenses for most software are designed to take away your ++freedom to share and change it. By contrast, the GNU General Public ++Licenses are intended to guarantee your freedom to share and change ++free software--to make sure the software is free for all its users. ++ ++ This license, the Lesser General Public License, applies to some ++specially designated software packages--typically libraries--of the ++Free Software Foundation and other authors who decide to use it. You ++can use it too, but we suggest you first think carefully about whether ++this license or the ordinary General Public License is the better ++strategy to use in any particular case, based on the explanations below. ++ ++ When we speak of free software, we are referring to freedom of use, ++not price. Our General Public Licenses are designed to make sure that ++you have the freedom to distribute copies of free software (and charge ++for this service if you wish); that you receive source code or can get ++it if you want it; that you can change the software and use pieces of ++it in new free programs; and that you are informed that you can do ++these things. ++ ++ To protect your rights, we need to make restrictions that forbid ++distributors to deny you these rights or to ask you to surrender these ++rights. These restrictions translate to certain responsibilities for ++you if you distribute copies of the library or if you modify it. ++ ++ For example, if you distribute copies of the library, whether gratis ++or for a fee, you must give the recipients all the rights that we gave ++you. You must make sure that they, too, receive or can get the source ++code. If you link other code with the library, you must provide ++complete object files to the recipients, so that they can relink them ++with the library after making changes to the library and recompiling ++it. And you must show them these terms so they know their rights. ++ ++ We protect your rights with a two-step method: (1) we copyright the ++library, and (2) we offer you this license, which gives you legal ++permission to copy, distribute and/or modify the library. ++ ++ To protect each distributor, we want to make it very clear that ++there is no warranty for the free library. Also, if the library is ++modified by someone else and passed on, the recipients should know ++that what they have is not the original version, so that the original ++author's reputation will not be affected by problems that might be ++introduced by others. ++ ++ Finally, software patents pose a constant threat to the existence of ++any free program. We wish to make sure that a company cannot ++effectively restrict the users of a free program by obtaining a ++restrictive license from a patent holder. Therefore, we insist that ++any patent license obtained for a version of the library must be ++consistent with the full freedom of use specified in this license. ++ ++ Most GNU software, including some libraries, is covered by the ++ordinary GNU General Public License. This license, the GNU Lesser ++General Public License, applies to certain designated libraries, and ++is quite different from the ordinary General Public License. We use ++this license for certain libraries in order to permit linking those ++libraries into non-free programs. ++ ++ When a program is linked with a library, whether statically or using ++a shared library, the combination of the two is legally speaking a ++combined work, a derivative of the original library. The ordinary ++General Public License therefore permits such linking only if the ++entire combination fits its criteria of freedom. The Lesser General ++Public License permits more lax criteria for linking other code with ++the library. ++ ++ We call this license the "Lesser" General Public License because it ++does Less to protect the user's freedom than the ordinary General ++Public License. It also provides other free software developers Less ++of an advantage over competing non-free programs. These disadvantages ++are the reason we use the ordinary General Public License for many ++libraries. However, the Lesser license provides advantages in certain ++special circumstances. ++ ++ For example, on rare occasions, there may be a special need to ++encourage the widest possible use of a certain library, so that it becomes ++a de-facto standard. To achieve this, non-free programs must be ++allowed to use the library. A more frequent case is that a free ++library does the same job as widely used non-free libraries. In this ++case, there is little to gain by limiting the free library to free ++software only, so we use the Lesser General Public License. ++ ++ In other cases, permission to use a particular library in non-free ++programs enables a greater number of people to use a large body of ++free software. For example, permission to use the GNU C Library in ++non-free programs enables many more people to use the whole GNU ++operating system, as well as its variant, the GNU/Linux operating ++system. ++ ++ Although the Lesser General Public License is Less protective of the ++users' freedom, it does ensure that the user of a program that is ++linked with the Library has the freedom and the wherewithal to run ++that program using a modified version of the Library. ++ ++ The precise terms and conditions for copying, distribution and ++modification follow. Pay close attention to the difference between a ++"work based on the library" and a "work that uses the library". The ++former contains code derived from the library, whereas the latter must ++be combined with the library in order to run. ++ ++ GNU LESSER GENERAL PUBLIC LICENSE ++ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION ++ ++ 0. This License Agreement applies to any software library or other ++program which contains a notice placed by the copyright holder or ++other authorized party saying it may be distributed under the terms of ++this Lesser General Public License (also called "this License"). ++Each licensee is addressed as "you". ++ ++ A "library" means a collection of software functions and/or data ++prepared so as to be conveniently linked with application programs ++(which use some of those functions and data) to form executables. ++ ++ The "Library", below, refers to any such software library or work ++which has been distributed under these terms. A "work based on the ++Library" means either the Library or any derivative work under ++copyright law: that is to say, a work containing the Library or a ++portion of it, either verbatim or with modifications and/or translated ++straightforwardly into another language. (Hereinafter, translation is ++included without limitation in the term "modification".) ++ ++ "Source code" for a work means the preferred form of the work for ++making modifications to it. For a library, complete source code means ++all the source code for all modules it contains, plus any associated ++interface definition files, plus the scripts used to control compilation ++and installation of the library. ++ ++ Activities other than copying, distribution and modification are not ++covered by this License; they are outside its scope. The act of ++running a program using the Library is not restricted, and output from ++such a program is covered only if its contents constitute a work based ++on the Library (independent of the use of the Library in a tool for ++writing it). Whether that is true depends on what the Library does ++and what the program that uses the Library does. ++ ++ 1. You may copy and distribute verbatim copies of the Library's ++complete source code as you receive it, in any medium, provided that ++you conspicuously and appropriately publish on each copy an ++appropriate copyright notice and disclaimer of warranty; keep intact ++all the notices that refer to this License and to the absence of any ++warranty; and distribute a copy of this License along with the ++Library. ++ ++ You may charge a fee for the physical act of transferring a copy, ++and you may at your option offer warranty protection in exchange for a ++fee. ++ ++ 2. You may modify your copy or copies of the Library or any portion ++of it, thus forming a work based on the Library, and copy and ++distribute such modifications or work under the terms of Section 1 ++above, provided that you also meet all of these conditions: ++ ++ a) The modified work must itself be a software library. ++ ++ b) You must cause the files modified to carry prominent notices ++ stating that you changed the files and the date of any change. ++ ++ c) You must cause the whole of the work to be licensed at no ++ charge to all third parties under the terms of this License. ++ ++ d) If a facility in the modified Library refers to a function or a ++ table of data to be supplied by an application program that uses ++ the facility, other than as an argument passed when the facility ++ is invoked, then you must make a good faith effort to ensure that, ++ in the event an application does not supply such function or ++ table, the facility still operates, and performs whatever part of ++ its purpose remains meaningful. ++ ++ (For example, a function in a library to compute square roots has ++ a purpose that is entirely well-defined independent of the ++ application. Therefore, Subsection 2d requires that any ++ application-supplied function or table used by this function must ++ be optional: if the application does not supply it, the square ++ root function must still compute square roots.) ++ ++These requirements apply to the modified work as a whole. If ++identifiable sections of that work are not derived from the Library, ++and can be reasonably considered independent and separate works in ++themselves, then this License, and its terms, do not apply to those ++sections when you distribute them as separate works. But when you ++distribute the same sections as part of a whole which is a work based ++on the Library, the distribution of the whole must be on the terms of ++this License, whose permissions for other licensees extend to the ++entire whole, and thus to each and every part regardless of who wrote ++it. ++ ++Thus, it is not the intent of this section to claim rights or contest ++your rights to work written entirely by you; rather, the intent is to ++exercise the right to control the distribution of derivative or ++collective works based on the Library. ++ ++In addition, mere aggregation of another work not based on the Library ++with the Library (or with a work based on the Library) on a volume of ++a storage or distribution medium does not bring the other work under ++the scope of this License. ++ ++ 3. You may opt to apply the terms of the ordinary GNU General Public ++License instead of this License to a given copy of the Library. To do ++this, you must alter all the notices that refer to this License, so ++that they refer to the ordinary GNU General Public License, version 2, ++instead of to this License. (If a newer version than version 2 of the ++ordinary GNU General Public License has appeared, then you can specify ++that version instead if you wish.) Do not make any other change in ++these notices. ++ ++ Once this change is made in a given copy, it is irreversible for ++that copy, so the ordinary GNU General Public License applies to all ++subsequent copies and derivative works made from that copy. ++ ++ This option is useful when you wish to copy part of the code of ++the Library into a program that is not a library. ++ ++ 4. You may copy and distribute the Library (or a portion or ++derivative of it, under Section 2) in object code or executable form ++under the terms of Sections 1 and 2 above provided that you accompany ++it with the complete corresponding machine-readable source code, which ++must be distributed under the terms of Sections 1 and 2 above on a ++medium customarily used for software interchange. ++ ++ If distribution of object code is made by offering access to copy ++from a designated place, then offering equivalent access to copy the ++source code from the same place satisfies the requirement to ++distribute the source code, even though third parties are not ++compelled to copy the source along with the object code. ++ ++ 5. A program that contains no derivative of any portion of the ++Library, but is designed to work with the Library by being compiled or ++linked with it, is called a "work that uses the Library". Such a ++work, in isolation, is not a derivative work of the Library, and ++therefore falls outside the scope of this License. ++ ++ However, linking a "work that uses the Library" with the Library ++creates an executable that is a derivative of the Library (because it ++contains portions of the Library), rather than a "work that uses the ++library". The executable is therefore covered by this License. ++Section 6 states terms for distribution of such executables. ++ ++ When a "work that uses the Library" uses material from a header file ++that is part of the Library, the object code for the work may be a ++derivative work of the Library even though the source code is not. ++Whether this is true is especially significant if the work can be ++linked without the Library, or if the work is itself a library. The ++threshold for this to be true is not precisely defined by law. ++ ++ If such an object file uses only numerical parameters, data ++structure layouts and accessors, and small macros and small inline ++functions (ten lines or less in length), then the use of the object ++file is unrestricted, regardless of whether it is legally a derivative ++work. (Executables containing this object code plus portions of the ++Library will still fall under Section 6.) ++ ++ Otherwise, if the work is a derivative of the Library, you may ++distribute the object code for the work under the terms of Section 6. ++Any executables containing that work also fall under Section 6, ++whether or not they are linked directly with the Library itself. ++ ++ 6. As an exception to the Sections above, you may also combine or ++link a "work that uses the Library" with the Library to produce a ++work containing portions of the Library, and distribute that work ++under terms of your choice, provided that the terms permit ++modification of the work for the customer's own use and reverse ++engineering for debugging such modifications. ++ ++ You must give prominent notice with each copy of the work that the ++Library is used in it and that the Library and its use are covered by ++this License. You must supply a copy of this License. If the work ++during execution displays copyright notices, you must include the ++copyright notice for the Library among them, as well as a reference ++directing the user to the copy of this License. Also, you must do one ++of these things: ++ ++ a) Accompany the work with the complete corresponding ++ machine-readable source code for the Library including whatever ++ changes were used in the work (which must be distributed under ++ Sections 1 and 2 above); and, if the work is an executable linked ++ with the Library, with the complete machine-readable "work that ++ uses the Library", as object code and/or source code, so that the ++ user can modify the Library and then relink to produce a modified ++ executable containing the modified Library. (It is understood ++ that the user who changes the contents of definitions files in the ++ Library will not necessarily be able to recompile the application ++ to use the modified definitions.) ++ ++ b) Use a suitable shared library mechanism for linking with the ++ Library. A suitable mechanism is one that (1) uses at run time a ++ copy of the library already present on the user's computer system, ++ rather than copying library functions into the executable, and (2) ++ will operate properly with a modified version of the library, if ++ the user installs one, as long as the modified version is ++ interface-compatible with the version that the work was made with. ++ ++ c) Accompany the work with a written offer, valid for at ++ least three years, to give the same user the materials ++ specified in Subsection 6a, above, for a charge no more ++ than the cost of performing this distribution. ++ ++ d) If distribution of the work is made by offering access to copy ++ from a designated place, offer equivalent access to copy the above ++ specified materials from the same place. ++ ++ e) Verify that the user has already received a copy of these ++ materials or that you have already sent this user a copy. ++ ++ For an executable, the required form of the "work that uses the ++Library" must include any data and utility programs needed for ++reproducing the executable from it. However, as a special exception, ++the materials to be distributed need not include anything that is ++normally distributed (in either source or binary form) with the major ++components (compiler, kernel, and so on) of the operating system on ++which the executable runs, unless that component itself accompanies ++the executable. ++ ++ It may happen that this requirement contradicts the license ++restrictions of other proprietary libraries that do not normally ++accompany the operating system. Such a contradiction means you cannot ++use both them and the Library together in an executable that you ++distribute. ++ ++ 7. You may place library facilities that are a work based on the ++Library side-by-side in a single library together with other library ++facilities not covered by this License, and distribute such a combined ++library, provided that the separate distribution of the work based on ++the Library and of the other library facilities is otherwise ++permitted, and provided that you do these two things: ++ ++ a) Accompany the combined library with a copy of the same work ++ based on the Library, uncombined with any other library ++ facilities. This must be distributed under the terms of the ++ Sections above. ++ ++ b) Give prominent notice with the combined library of the fact ++ that part of it is a work based on the Library, and explaining ++ where to find the accompanying uncombined form of the same work. ++ ++ 8. You may not copy, modify, sublicense, link with, or distribute ++the Library except as expressly provided under this License. Any ++attempt otherwise to copy, modify, sublicense, link with, or ++distribute the Library is void, and will automatically terminate your ++rights under this License. However, parties who have received copies, ++or rights, from you under this License will not have their licenses ++terminated so long as such parties remain in full compliance. ++ ++ 9. You are not required to accept this License, since you have not ++signed it. However, nothing else grants you permission to modify or ++distribute the Library or its derivative works. These actions are ++prohibited by law if you do not accept this License. Therefore, by ++modifying or distributing the Library (or any work based on the ++Library), you indicate your acceptance of this License to do so, and ++all its terms and conditions for copying, distributing or modifying ++the Library or works based on it. ++ ++ 10. Each time you redistribute the Library (or any work based on the ++Library), the recipient automatically receives a license from the ++original licensor to copy, distribute, link with or modify the Library ++subject to these terms and conditions. You may not impose any further ++restrictions on the recipients' exercise of the rights granted herein. ++You are not responsible for enforcing compliance by third parties with ++this License. ++ ++ 11. If, as a consequence of a court judgment or allegation of patent ++infringement or for any other reason (not limited to patent issues), ++conditions are imposed on you (whether by court order, agreement or ++otherwise) that contradict the conditions of this License, they do not ++excuse you from the conditions of this License. If you cannot ++distribute so as to satisfy simultaneously your obligations under this ++License and any other pertinent obligations, then as a consequence you ++may not distribute the Library at all. For example, if a patent ++license would not permit royalty-free redistribution of the Library by ++all those who receive copies directly or indirectly through you, then ++the only way you could satisfy both it and this License would be to ++refrain entirely from distribution of the Library. ++ ++If any portion of this section is held invalid or unenforceable under any ++particular circumstance, the balance of the section is intended to apply, ++and the section as a whole is intended to apply in other circumstances. ++ ++It is not the purpose of this section to induce you to infringe any ++patents or other property right claims or to contest validity of any ++such claims; this section has the sole purpose of protecting the ++integrity of the free software distribution system which is ++implemented by public license practices. Many people have made ++generous contributions to the wide range of software distributed ++through that system in reliance on consistent application of that ++system; it is up to the author/donor to decide if he or she is willing ++to distribute software through any other system and a licensee cannot ++impose that choice. ++ ++This section is intended to make thoroughly clear what is believed to ++be a consequence of the rest of this License. ++ ++ 12. If the distribution and/or use of the Library is restricted in ++certain countries either by patents or by copyrighted interfaces, the ++original copyright holder who places the Library under this License may add ++an explicit geographical distribution limitation excluding those countries, ++so that distribution is permitted only in or among countries not thus ++excluded. In such case, this License incorporates the limitation as if ++written in the body of this License. ++ ++ 13. The Free Software Foundation may publish revised and/or new ++versions of the Lesser General Public License from time to time. ++Such new versions will be similar in spirit to the present version, ++but may differ in detail to address new problems or concerns. ++ ++Each version is given a distinguishing version number. If the Library ++specifies a version number of this License which applies to it and ++"any later version", you have the option of following the terms and ++conditions either of that version or of any later version published by ++the Free Software Foundation. If the Library does not specify a ++license version number, you may choose any version ever published by ++the Free Software Foundation. ++ ++ 14. If you wish to incorporate parts of the Library into other free ++programs whose distribution conditions are incompatible with these, ++write to the author to ask for permission. For software which is ++copyrighted by the Free Software Foundation, write to the Free ++Software Foundation; we sometimes make exceptions for this. Our ++decision will be guided by the two goals of preserving the free status ++of all derivatives of our free software and of promoting the sharing ++and reuse of software generally. ++ ++ NO WARRANTY ++ ++ 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO ++WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. ++EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR ++OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY ++KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE ++IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR ++PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE ++LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME ++THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. ++ ++ 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN ++WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY ++AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU ++FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR ++CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE ++LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING ++RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A ++FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF ++SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH ++DAMAGES. ++ ++ END OF TERMS AND CONDITIONS ++ ++ How to Apply These Terms to Your New Libraries ++ ++ If you develop a new library, and you want it to be of the greatest ++possible use to the public, we recommend making it free software that ++everyone can redistribute and change. You can do so by permitting ++redistribution under these terms (or, alternatively, under the terms of the ++ordinary General Public License). ++ ++ To apply these terms, attach the following notices to the library. It is ++safest to attach them to the start of each source file to most effectively ++convey the exclusion of warranty; and each file should have at least the ++"copyright" line and a pointer to where the full notice is found. ++ ++ ++ Copyright (C) ++ ++ This library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ This library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with this library; if not, write to the Free Software ++ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ++ ++Also add information on how to contact you by electronic and paper mail. ++ ++You should also get your employer (if you work as a programmer) or your ++school, if any, to sign a "copyright disclaimer" for the library, if ++necessary. Here is a sample; alter the names: ++ ++ Yoyodyne, Inc., hereby disclaims all copyright interest in the ++ library `Frob' (a library for tweaking knobs) written by James Random Hacker. ++ ++ , 1 April 1990 ++ Ty Coon, President of Vice ++ ++That's all there is to it! ++ ++ +diff --git a/libudev/COPYING b/libudev/COPYING +new file mode 100644 +index 0000000..8add30a +--- /dev/null ++++ b/libudev/COPYING +@@ -0,0 +1,504 @@ ++ GNU LESSER GENERAL PUBLIC LICENSE ++ Version 2.1, February 1999 ++ ++ Copyright (C) 1991, 1999 Free Software Foundation, Inc. ++ 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ++ Everyone is permitted to copy and distribute verbatim copies ++ of this license document, but changing it is not allowed. ++ ++[This is the first released version of the Lesser GPL. It also counts ++ as the successor of the GNU Library Public License, version 2, hence ++ the version number 2.1.] ++ ++ Preamble ++ ++ The licenses for most software are designed to take away your ++freedom to share and change it. By contrast, the GNU General Public ++Licenses are intended to guarantee your freedom to share and change ++free software--to make sure the software is free for all its users. ++ ++ This license, the Lesser General Public License, applies to some ++specially designated software packages--typically libraries--of the ++Free Software Foundation and other authors who decide to use it. You ++can use it too, but we suggest you first think carefully about whether ++this license or the ordinary General Public License is the better ++strategy to use in any particular case, based on the explanations below. ++ ++ When we speak of free software, we are referring to freedom of use, ++not price. Our General Public Licenses are designed to make sure that ++you have the freedom to distribute copies of free software (and charge ++for this service if you wish); that you receive source code or can get ++it if you want it; that you can change the software and use pieces of ++it in new free programs; and that you are informed that you can do ++these things. ++ ++ To protect your rights, we need to make restrictions that forbid ++distributors to deny you these rights or to ask you to surrender these ++rights. These restrictions translate to certain responsibilities for ++you if you distribute copies of the library or if you modify it. ++ ++ For example, if you distribute copies of the library, whether gratis ++or for a fee, you must give the recipients all the rights that we gave ++you. You must make sure that they, too, receive or can get the source ++code. If you link other code with the library, you must provide ++complete object files to the recipients, so that they can relink them ++with the library after making changes to the library and recompiling ++it. And you must show them these terms so they know their rights. ++ ++ We protect your rights with a two-step method: (1) we copyright the ++library, and (2) we offer you this license, which gives you legal ++permission to copy, distribute and/or modify the library. ++ ++ To protect each distributor, we want to make it very clear that ++there is no warranty for the free library. Also, if the library is ++modified by someone else and passed on, the recipients should know ++that what they have is not the original version, so that the original ++author's reputation will not be affected by problems that might be ++introduced by others. ++ ++ Finally, software patents pose a constant threat to the existence of ++any free program. We wish to make sure that a company cannot ++effectively restrict the users of a free program by obtaining a ++restrictive license from a patent holder. Therefore, we insist that ++any patent license obtained for a version of the library must be ++consistent with the full freedom of use specified in this license. ++ ++ Most GNU software, including some libraries, is covered by the ++ordinary GNU General Public License. This license, the GNU Lesser ++General Public License, applies to certain designated libraries, and ++is quite different from the ordinary General Public License. We use ++this license for certain libraries in order to permit linking those ++libraries into non-free programs. ++ ++ When a program is linked with a library, whether statically or using ++a shared library, the combination of the two is legally speaking a ++combined work, a derivative of the original library. The ordinary ++General Public License therefore permits such linking only if the ++entire combination fits its criteria of freedom. The Lesser General ++Public License permits more lax criteria for linking other code with ++the library. ++ ++ We call this license the "Lesser" General Public License because it ++does Less to protect the user's freedom than the ordinary General ++Public License. It also provides other free software developers Less ++of an advantage over competing non-free programs. These disadvantages ++are the reason we use the ordinary General Public License for many ++libraries. However, the Lesser license provides advantages in certain ++special circumstances. ++ ++ For example, on rare occasions, there may be a special need to ++encourage the widest possible use of a certain library, so that it becomes ++a de-facto standard. To achieve this, non-free programs must be ++allowed to use the library. A more frequent case is that a free ++library does the same job as widely used non-free libraries. In this ++case, there is little to gain by limiting the free library to free ++software only, so we use the Lesser General Public License. ++ ++ In other cases, permission to use a particular library in non-free ++programs enables a greater number of people to use a large body of ++free software. For example, permission to use the GNU C Library in ++non-free programs enables many more people to use the whole GNU ++operating system, as well as its variant, the GNU/Linux operating ++system. ++ ++ Although the Lesser General Public License is Less protective of the ++users' freedom, it does ensure that the user of a program that is ++linked with the Library has the freedom and the wherewithal to run ++that program using a modified version of the Library. ++ ++ The precise terms and conditions for copying, distribution and ++modification follow. Pay close attention to the difference between a ++"work based on the library" and a "work that uses the library". The ++former contains code derived from the library, whereas the latter must ++be combined with the library in order to run. ++ ++ GNU LESSER GENERAL PUBLIC LICENSE ++ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION ++ ++ 0. This License Agreement applies to any software library or other ++program which contains a notice placed by the copyright holder or ++other authorized party saying it may be distributed under the terms of ++this Lesser General Public License (also called "this License"). ++Each licensee is addressed as "you". ++ ++ A "library" means a collection of software functions and/or data ++prepared so as to be conveniently linked with application programs ++(which use some of those functions and data) to form executables. ++ ++ The "Library", below, refers to any such software library or work ++which has been distributed under these terms. A "work based on the ++Library" means either the Library or any derivative work under ++copyright law: that is to say, a work containing the Library or a ++portion of it, either verbatim or with modifications and/or translated ++straightforwardly into another language. (Hereinafter, translation is ++included without limitation in the term "modification".) ++ ++ "Source code" for a work means the preferred form of the work for ++making modifications to it. For a library, complete source code means ++all the source code for all modules it contains, plus any associated ++interface definition files, plus the scripts used to control compilation ++and installation of the library. ++ ++ Activities other than copying, distribution and modification are not ++covered by this License; they are outside its scope. The act of ++running a program using the Library is not restricted, and output from ++such a program is covered only if its contents constitute a work based ++on the Library (independent of the use of the Library in a tool for ++writing it). Whether that is true depends on what the Library does ++and what the program that uses the Library does. ++ ++ 1. You may copy and distribute verbatim copies of the Library's ++complete source code as you receive it, in any medium, provided that ++you conspicuously and appropriately publish on each copy an ++appropriate copyright notice and disclaimer of warranty; keep intact ++all the notices that refer to this License and to the absence of any ++warranty; and distribute a copy of this License along with the ++Library. ++ ++ You may charge a fee for the physical act of transferring a copy, ++and you may at your option offer warranty protection in exchange for a ++fee. ++ ++ 2. You may modify your copy or copies of the Library or any portion ++of it, thus forming a work based on the Library, and copy and ++distribute such modifications or work under the terms of Section 1 ++above, provided that you also meet all of these conditions: ++ ++ a) The modified work must itself be a software library. ++ ++ b) You must cause the files modified to carry prominent notices ++ stating that you changed the files and the date of any change. ++ ++ c) You must cause the whole of the work to be licensed at no ++ charge to all third parties under the terms of this License. ++ ++ d) If a facility in the modified Library refers to a function or a ++ table of data to be supplied by an application program that uses ++ the facility, other than as an argument passed when the facility ++ is invoked, then you must make a good faith effort to ensure that, ++ in the event an application does not supply such function or ++ table, the facility still operates, and performs whatever part of ++ its purpose remains meaningful. ++ ++ (For example, a function in a library to compute square roots has ++ a purpose that is entirely well-defined independent of the ++ application. Therefore, Subsection 2d requires that any ++ application-supplied function or table used by this function must ++ be optional: if the application does not supply it, the square ++ root function must still compute square roots.) ++ ++These requirements apply to the modified work as a whole. If ++identifiable sections of that work are not derived from the Library, ++and can be reasonably considered independent and separate works in ++themselves, then this License, and its terms, do not apply to those ++sections when you distribute them as separate works. But when you ++distribute the same sections as part of a whole which is a work based ++on the Library, the distribution of the whole must be on the terms of ++this License, whose permissions for other licensees extend to the ++entire whole, and thus to each and every part regardless of who wrote ++it. ++ ++Thus, it is not the intent of this section to claim rights or contest ++your rights to work written entirely by you; rather, the intent is to ++exercise the right to control the distribution of derivative or ++collective works based on the Library. ++ ++In addition, mere aggregation of another work not based on the Library ++with the Library (or with a work based on the Library) on a volume of ++a storage or distribution medium does not bring the other work under ++the scope of this License. ++ ++ 3. You may opt to apply the terms of the ordinary GNU General Public ++License instead of this License to a given copy of the Library. To do ++this, you must alter all the notices that refer to this License, so ++that they refer to the ordinary GNU General Public License, version 2, ++instead of to this License. (If a newer version than version 2 of the ++ordinary GNU General Public License has appeared, then you can specify ++that version instead if you wish.) Do not make any other change in ++these notices. ++ ++ Once this change is made in a given copy, it is irreversible for ++that copy, so the ordinary GNU General Public License applies to all ++subsequent copies and derivative works made from that copy. ++ ++ This option is useful when you wish to copy part of the code of ++the Library into a program that is not a library. ++ ++ 4. You may copy and distribute the Library (or a portion or ++derivative of it, under Section 2) in object code or executable form ++under the terms of Sections 1 and 2 above provided that you accompany ++it with the complete corresponding machine-readable source code, which ++must be distributed under the terms of Sections 1 and 2 above on a ++medium customarily used for software interchange. ++ ++ If distribution of object code is made by offering access to copy ++from a designated place, then offering equivalent access to copy the ++source code from the same place satisfies the requirement to ++distribute the source code, even though third parties are not ++compelled to copy the source along with the object code. ++ ++ 5. A program that contains no derivative of any portion of the ++Library, but is designed to work with the Library by being compiled or ++linked with it, is called a "work that uses the Library". Such a ++work, in isolation, is not a derivative work of the Library, and ++therefore falls outside the scope of this License. ++ ++ However, linking a "work that uses the Library" with the Library ++creates an executable that is a derivative of the Library (because it ++contains portions of the Library), rather than a "work that uses the ++library". The executable is therefore covered by this License. ++Section 6 states terms for distribution of such executables. ++ ++ When a "work that uses the Library" uses material from a header file ++that is part of the Library, the object code for the work may be a ++derivative work of the Library even though the source code is not. ++Whether this is true is especially significant if the work can be ++linked without the Library, or if the work is itself a library. The ++threshold for this to be true is not precisely defined by law. ++ ++ If such an object file uses only numerical parameters, data ++structure layouts and accessors, and small macros and small inline ++functions (ten lines or less in length), then the use of the object ++file is unrestricted, regardless of whether it is legally a derivative ++work. (Executables containing this object code plus portions of the ++Library will still fall under Section 6.) ++ ++ Otherwise, if the work is a derivative of the Library, you may ++distribute the object code for the work under the terms of Section 6. ++Any executables containing that work also fall under Section 6, ++whether or not they are linked directly with the Library itself. ++ ++ 6. As an exception to the Sections above, you may also combine or ++link a "work that uses the Library" with the Library to produce a ++work containing portions of the Library, and distribute that work ++under terms of your choice, provided that the terms permit ++modification of the work for the customer's own use and reverse ++engineering for debugging such modifications. ++ ++ You must give prominent notice with each copy of the work that the ++Library is used in it and that the Library and its use are covered by ++this License. You must supply a copy of this License. If the work ++during execution displays copyright notices, you must include the ++copyright notice for the Library among them, as well as a reference ++directing the user to the copy of this License. Also, you must do one ++of these things: ++ ++ a) Accompany the work with the complete corresponding ++ machine-readable source code for the Library including whatever ++ changes were used in the work (which must be distributed under ++ Sections 1 and 2 above); and, if the work is an executable linked ++ with the Library, with the complete machine-readable "work that ++ uses the Library", as object code and/or source code, so that the ++ user can modify the Library and then relink to produce a modified ++ executable containing the modified Library. (It is understood ++ that the user who changes the contents of definitions files in the ++ Library will not necessarily be able to recompile the application ++ to use the modified definitions.) ++ ++ b) Use a suitable shared library mechanism for linking with the ++ Library. A suitable mechanism is one that (1) uses at run time a ++ copy of the library already present on the user's computer system, ++ rather than copying library functions into the executable, and (2) ++ will operate properly with a modified version of the library, if ++ the user installs one, as long as the modified version is ++ interface-compatible with the version that the work was made with. ++ ++ c) Accompany the work with a written offer, valid for at ++ least three years, to give the same user the materials ++ specified in Subsection 6a, above, for a charge no more ++ than the cost of performing this distribution. ++ ++ d) If distribution of the work is made by offering access to copy ++ from a designated place, offer equivalent access to copy the above ++ specified materials from the same place. ++ ++ e) Verify that the user has already received a copy of these ++ materials or that you have already sent this user a copy. ++ ++ For an executable, the required form of the "work that uses the ++Library" must include any data and utility programs needed for ++reproducing the executable from it. However, as a special exception, ++the materials to be distributed need not include anything that is ++normally distributed (in either source or binary form) with the major ++components (compiler, kernel, and so on) of the operating system on ++which the executable runs, unless that component itself accompanies ++the executable. ++ ++ It may happen that this requirement contradicts the license ++restrictions of other proprietary libraries that do not normally ++accompany the operating system. Such a contradiction means you cannot ++use both them and the Library together in an executable that you ++distribute. ++ ++ 7. You may place library facilities that are a work based on the ++Library side-by-side in a single library together with other library ++facilities not covered by this License, and distribute such a combined ++library, provided that the separate distribution of the work based on ++the Library and of the other library facilities is otherwise ++permitted, and provided that you do these two things: ++ ++ a) Accompany the combined library with a copy of the same work ++ based on the Library, uncombined with any other library ++ facilities. This must be distributed under the terms of the ++ Sections above. ++ ++ b) Give prominent notice with the combined library of the fact ++ that part of it is a work based on the Library, and explaining ++ where to find the accompanying uncombined form of the same work. ++ ++ 8. You may not copy, modify, sublicense, link with, or distribute ++the Library except as expressly provided under this License. Any ++attempt otherwise to copy, modify, sublicense, link with, or ++distribute the Library is void, and will automatically terminate your ++rights under this License. However, parties who have received copies, ++or rights, from you under this License will not have their licenses ++terminated so long as such parties remain in full compliance. ++ ++ 9. You are not required to accept this License, since you have not ++signed it. However, nothing else grants you permission to modify or ++distribute the Library or its derivative works. These actions are ++prohibited by law if you do not accept this License. Therefore, by ++modifying or distributing the Library (or any work based on the ++Library), you indicate your acceptance of this License to do so, and ++all its terms and conditions for copying, distributing or modifying ++the Library or works based on it. ++ ++ 10. Each time you redistribute the Library (or any work based on the ++Library), the recipient automatically receives a license from the ++original licensor to copy, distribute, link with or modify the Library ++subject to these terms and conditions. You may not impose any further ++restrictions on the recipients' exercise of the rights granted herein. ++You are not responsible for enforcing compliance by third parties with ++this License. ++ ++ 11. If, as a consequence of a court judgment or allegation of patent ++infringement or for any other reason (not limited to patent issues), ++conditions are imposed on you (whether by court order, agreement or ++otherwise) that contradict the conditions of this License, they do not ++excuse you from the conditions of this License. If you cannot ++distribute so as to satisfy simultaneously your obligations under this ++License and any other pertinent obligations, then as a consequence you ++may not distribute the Library at all. For example, if a patent ++license would not permit royalty-free redistribution of the Library by ++all those who receive copies directly or indirectly through you, then ++the only way you could satisfy both it and this License would be to ++refrain entirely from distribution of the Library. ++ ++If any portion of this section is held invalid or unenforceable under any ++particular circumstance, the balance of the section is intended to apply, ++and the section as a whole is intended to apply in other circumstances. ++ ++It is not the purpose of this section to induce you to infringe any ++patents or other property right claims or to contest validity of any ++such claims; this section has the sole purpose of protecting the ++integrity of the free software distribution system which is ++implemented by public license practices. Many people have made ++generous contributions to the wide range of software distributed ++through that system in reliance on consistent application of that ++system; it is up to the author/donor to decide if he or she is willing ++to distribute software through any other system and a licensee cannot ++impose that choice. ++ ++This section is intended to make thoroughly clear what is believed to ++be a consequence of the rest of this License. ++ ++ 12. If the distribution and/or use of the Library is restricted in ++certain countries either by patents or by copyrighted interfaces, the ++original copyright holder who places the Library under this License may add ++an explicit geographical distribution limitation excluding those countries, ++so that distribution is permitted only in or among countries not thus ++excluded. In such case, this License incorporates the limitation as if ++written in the body of this License. ++ ++ 13. The Free Software Foundation may publish revised and/or new ++versions of the Lesser General Public License from time to time. ++Such new versions will be similar in spirit to the present version, ++but may differ in detail to address new problems or concerns. ++ ++Each version is given a distinguishing version number. If the Library ++specifies a version number of this License which applies to it and ++"any later version", you have the option of following the terms and ++conditions either of that version or of any later version published by ++the Free Software Foundation. If the Library does not specify a ++license version number, you may choose any version ever published by ++the Free Software Foundation. ++ ++ 14. If you wish to incorporate parts of the Library into other free ++programs whose distribution conditions are incompatible with these, ++write to the author to ask for permission. For software which is ++copyrighted by the Free Software Foundation, write to the Free ++Software Foundation; we sometimes make exceptions for this. Our ++decision will be guided by the two goals of preserving the free status ++of all derivatives of our free software and of promoting the sharing ++and reuse of software generally. ++ ++ NO WARRANTY ++ ++ 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO ++WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. ++EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR ++OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY ++KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE ++IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR ++PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE ++LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME ++THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. ++ ++ 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN ++WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY ++AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU ++FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR ++CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE ++LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING ++RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A ++FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF ++SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH ++DAMAGES. ++ ++ END OF TERMS AND CONDITIONS ++ ++ How to Apply These Terms to Your New Libraries ++ ++ If you develop a new library, and you want it to be of the greatest ++possible use to the public, we recommend making it free software that ++everyone can redistribute and change. You can do so by permitting ++redistribution under these terms (or, alternatively, under the terms of the ++ordinary General Public License). ++ ++ To apply these terms, attach the following notices to the library. It is ++safest to attach them to the start of each source file to most effectively ++convey the exclusion of warranty; and each file should have at least the ++"copyright" line and a pointer to where the full notice is found. ++ ++ ++ Copyright (C) ++ ++ This library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ This library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with this library; if not, write to the Free Software ++ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ++ ++Also add information on how to contact you by electronic and paper mail. ++ ++You should also get your employer (if you work as a programmer) or your ++school, if any, to sign a "copyright disclaimer" for the library, if ++necessary. Here is a sample; alter the names: ++ ++ Yoyodyne, Inc., hereby disclaims all copyright interest in the ++ library `Frob' (a library for tweaking knobs) written by James Random Hacker. ++ ++ , 1 April 1990 ++ Ty Coon, President of Vice ++ ++That's all there is to it! ++ ++ +-- +1.6.6 + diff --git a/0110-cdrom_id-only-mark-sr-0-9-as-ID_CDROM.patch b/0110-cdrom_id-only-mark-sr-0-9-as-ID_CDROM.patch new file mode 100644 index 0000000..cc4a088 --- /dev/null +++ b/0110-cdrom_id-only-mark-sr-0-9-as-ID_CDROM.patch @@ -0,0 +1,26 @@ +From 155e313bfda594b3d8e2a31d48f341765bdfa75d Mon Sep 17 00:00:00 2001 +From: Harald Hoyer +Date: Tue, 27 Apr 2010 12:22:42 +0200 +Subject: [PATCH 110/110] cdrom_id: only mark sr[0-9]* as ID_CDROM + +we cannot be sure for xvd* +--- + extras/cdrom_id/60-cdrom_id.rules | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/extras/cdrom_id/60-cdrom_id.rules b/extras/cdrom_id/60-cdrom_id.rules +index 16b3af9..b3109f1 100644 +--- a/extras/cdrom_id/60-cdrom_id.rules ++++ b/extras/cdrom_id/60-cdrom_id.rules +@@ -5,7 +5,7 @@ SUBSYSTEM!="block", GOTO="cdrom_end" + KERNEL!="sr[0-9]*|xvd*", GOTO="cdrom_end" + ENV{DEVTYPE}!="disk", GOTO="cdrom_end" + +-ENV{ID_CDROM}="1" ++KERNEL=="sr[0-9]*", ENV{ID_CDROM}="1" + IMPORT{program}="cdrom_id --export $tempnode" + + LABEL="cdrom_end" +-- +1.7.0.1 + diff --git a/40-ia64.rules b/40-ia64.rules new file mode 100644 index 0000000..5846f88 --- /dev/null +++ b/40-ia64.rules @@ -0,0 +1,4 @@ +# do not edit this file, it will be overwritten on update + +KERNEL=="sgi_*", MODE="0666" + diff --git a/40-isdn.rules b/40-isdn.rules new file mode 100644 index 0000000..1a31cb6 --- /dev/null +++ b/40-isdn.rules @@ -0,0 +1,4 @@ +# do not edit this file, it will be overwritten on update + +SUBSYSTEM=="capi", KERNEL=="capi", NAME="capi20", GROUP="dialout" +SUBSYSTEM=="tty", KERNEL=="capi[0-9]*", NAME="capi/%n" diff --git a/40-ppc.rules b/40-ppc.rules new file mode 100644 index 0000000..90c15f0 --- /dev/null +++ b/40-ppc.rules @@ -0,0 +1,6 @@ +# do not edit this file, it will be overwritten on update + +KERNEL=="iseries/ibmsis*", GROUP="disk" +KERNEL=="iseries/nvt*", GROUP="disk" +KERNEL=="iseries/vt*", GROUP="disk" +KERNEL=="iseries/vtty*, GROUP="dialout" diff --git a/40-s390.rules b/40-s390.rules new file mode 100644 index 0000000..43035db --- /dev/null +++ b/40-s390.rules @@ -0,0 +1,4 @@ +# do not edit this file, it will be overwritten on update + +KERNEL=="z90crypt", MODE="0666" + diff --git a/64-device-mapper.rules b/64-device-mapper.rules new file mode 100644 index 0000000..8154ef3 --- /dev/null +++ b/64-device-mapper.rules @@ -0,0 +1,4 @@ +# do not edit this file, it will be overwritten on update + +KERNEL=="device-mapper", NAME="mapper/control" + diff --git a/64-md-raid.rules b/64-md-raid.rules new file mode 100644 index 0000000..6ba93b6 --- /dev/null +++ b/64-md-raid.rules @@ -0,0 +1,36 @@ +# do not edit this file, it will be overwritten on update + +SUBSYSTEM!="block", GOTO="md_end" +ACTION!="add|change", GOTO="md_end" + +# import data from a raid member and activate it +#ENV{ID_FS_TYPE}=="linux_raid_member", IMPORT{program}="/sbin/mdadm --examine --export $tempnode", RUN+="/sbin/mdadm --incremental $env{DEVNAME}" +# import data from a raid set +KERNEL!="md*", GOTO="md_end" + +# partitions have no md/{array_state,metadata_version} +ENV{DEVTYPE}=="partition", GOTO="md_ignore_state" + +# container devices have a metadata version of e.g. 'external:ddf' and +# never leave state 'inactive' +ATTR{md/metadata_version}=="external:[A-Za-z]*", ATTR{md/array_state}=="inactive", GOTO="md_ignore_state" +TEST!="md/array_state", GOTO="md_end" +ATTR{md/array_state}=="|clear|inactive", GOTO="md_end" +LABEL="md_ignore_state" + +IMPORT{program}="/sbin/mdadm --detail --export $tempnode" +ENV{DEVTYPE}=="disk", ENV{MD_NAME}=="?*", SYMLINK+="disk/by-id/md-name-$env{MD_NAME}", OPTIONS+="string_escape=replace" +ENV{DEVTYPE}=="disk", ENV{MD_UUID}=="?*", SYMLINK+="disk/by-id/md-uuid-$env{MD_UUID}" +ENV{DEVTYPE}=="disk", ENV{MD_DEVNAME}=="?*", SYMLINK+="md/$env{MD_DEVNAME}" +ENV{DEVTYPE}=="partition", ENV{MD_NAME}=="?*", SYMLINK+="disk/by-id/md-name-$env{MD_NAME}-part%n", OPTIONS+="string_escape=replace" +ENV{DEVTYPE}=="partition", ENV{MD_UUID}=="?*", SYMLINK+="disk/by-id/md-uuid-$env{MD_UUID}-part%n" +ENV{DEVTYPE}=="partition", ENV{MD_DEVNAME}=="*[^0-9]", SYMLINK+="md/$env{MD_DEVNAME}%n" +ENV{DEVTYPE}=="partition", ENV{MD_DEVNAME}=="*[0-9]", SYMLINK+="md/$env{MD_DEVNAME}p%n" + +IMPORT{program}="/sbin/blkid -o udev -p $tempnode" +OPTIONS+="link_priority=100" +OPTIONS+="watch" +ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{ID_FS_UUID_ENC}=="?*", SYMLINK+="disk/by-uuid/$env{ID_FS_UUID_ENC}" +ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_FS_LABEL_ENC}=="?*", SYMLINK+="disk/by-label/$env{ID_FS_LABEL_ENC}" + +LABEL="md_end" diff --git a/Makefile b/Makefile deleted file mode 100644 index c72f44b..0000000 --- a/Makefile +++ /dev/null @@ -1,22 +0,0 @@ -# Makefile for source rpm: udev -# $Id: Makefile,v 1.3 2007/10/15 19:29:11 notting Exp $ -NAME := udev -SPECFILE = $(firstword $(wildcard *.spec)) -UPSTREAM_CHECKS = sign - -define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done -endef - -MAKEFILE_COMMON := $(shell $(find-makefile-common)) - -ifeq ($(MAKEFILE_COMMON),) -# attempt a checkout -define checkout-makefile-common -test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 -endef - -MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) -endif - -include $(MAKEFILE_COMMON) diff --git a/Makefile.git b/Makefile.git index ea5486a..d14c2d2 100644 --- a/Makefile.git +++ b/Makefile.git @@ -1,6 +1,6 @@ Patch: - @for i in 00*.patch; do n=$$[$$(echo $$i|cut -f 1 -d '-'|sed -e 's#^0*##')]; echo "Patch$$n: $$i";done + @for i in 0*.patch; do n=$$[$$(echo $$i|cut -f 1 -d '-'|sed -e 's#^0*##')]; echo "Patch$$n: $$i";done patch: - @for i in 00*.patch; do n=$$[$$(echo $$i|cut -f 1 -d '-'|sed -e 's#^0*##')]; echo "%patch$$n -p1 -b .git$$n";done + @for i in 0*.patch; do n=$$[$$(echo $$i|cut -f 1 -d '-'|sed -e 's#^0*##')]; echo "%patch$$n -p1 -b .git$$n";done diff --git a/sources b/sources index 3161bc7..c94ae06 100644 --- a/sources +++ b/sources @@ -1 +1,2 @@ -aeae0e6273dcbec246c3c1b9868ebed1 udev-151.tar.bz2 +76d12a9d97c3409e9ef60a4288227e8f udev-153.tar.bz2 +962e6d9b7fcf45432b361e3116923a3a udev-153.tar.bz2.sign diff --git a/start_udev b/start_udev index 57801aa..9e88dbc 100755 --- a/start_udev +++ b/start_udev @@ -55,8 +55,16 @@ if [ -n "$selinuxfs" ] && [ "`cat /proc/self/attr/current`" != "kernel" ]; then SELINUX_STATE=1 fi fi +[ -c /dev/systty ] && ln -fs tty0 /dev/systty - +touch_recursive() { + ( cd $1; + for i in *; do + [[ -c "$i" || -b "$i" ]] && touch --no-create "$i" + [ -d "$i" ] && touch_recursive "$i" + done ) + return 0 +} xargs_simple () { if [ "$1" = "-n" ]; then @@ -94,10 +102,11 @@ make_extra_nodes () { [ -d $udev_root/pts ] || mkdir -m 0755 $udev_root/pts [ -d $udev_root/shm ] || mkdir -m 0755 $udev_root/shm + [ -d $udev_root/hugepages ] || mkdir -m 0755 $udev_root/hugepages [ -a /dev/MAKEDEV ] || ln -s $MAKEDEV /dev/MAKEDEV; USE_MD5="false" - [ -x /usr/bin/md5sum -a "$UDEV_USE_MAKEDEV_CACHE" == "yes" ] && USE_MD5="true" + [[ "$UDEV_USE_MAKEDEV_CACHE" == "yes" && -x /usr/bin/md5sum ]] && USE_MD5="true" for i in 0 1 2 3 4 5 6 7; do [ -b /dev/loop$i ] || /bin/mknod -m 0640 /dev/loop$i b 7 $i @@ -157,9 +166,11 @@ make_extra_nodes () { if [ "$1" != "*" ]; then #echo "Warning: $devdir is deprecated. Please use /etc/udev/makedev.d/." cp -ar "$@" $udev_root/ - pushd "$udev_root" &> "$udev_root/null" - [ -x /sbin/restorecon ] && /sbin/restorecon "$@" - popd &> "$udev_root/null" + if [ -x /sbin/restorecon ]; then + pushd "$udev_root" &> "$udev_root/null" + /sbin/restorecon "$@" + popd &> "$udev_root/null" + fi fi popd &> "$udev_root/null" done @@ -224,11 +235,11 @@ echo -n "$STRING" # mount the tmpfs on ${udev_root%/}, if not already done LANG=C awk "\$2 == \"${udev_root%/}\" && ( \$3 == \"devtmpfs\" || \$3 == \"tmpfs\" ) { exit 1 }" /proc/mounts && { - if LANG=C fgrep -q "none ${udev_root%/}/pts " /proc/mounts; then + if LANG=C grep -Fq "none ${udev_root%/}/pts " /proc/mounts; then PTSDIR=$(mktemp -d) mount --move $udev_root/pts "$PTSDIR" fi - if LANG=C fgrep -q "none ${udev_root%/}/shm " /proc/mounts; then + if LANG=C grep -Fq "none ${udev_root%/}/shm " /proc/mounts; then SHMDIR=$(mktemp -d) mount --move $udev_root/shm "$SHMDIR" fi @@ -250,15 +261,14 @@ LANG=C awk "\$2 == \"${udev_root%/}\" && ( \$3 == \"devtmpfs\" || \$3 == \"tmpfs } make_extra_nodes -cmdline=$(cat /proc/cmdline) kill_udevd > "$udev_root/null" 2>&1 -rm -fr $udev_root/.udev > "$udev_root/null" 2>&1 -mkdir -p $udev_root/.udev > "$udev_root/null" 2>&1 UDEV_OPTS="" if [ -f "/sys/class/tty/console/uevent" ]; then # trigger the sorted events echo -e '\000\000\000\000' > /proc/sys/kernel/hotplug + cmdline=$(cat /proc/cmdline) + if strstr "$cmdline" udevtrace; then UDEV_OPTS="$UDEV_OPTS --debug-trace" fi @@ -284,6 +294,9 @@ if [ -f "/sys/class/tty/console/uevent" ]; then if strstr "$cmdline" udevchilds; then /sbin/udevadm control --max-childs=$(getval udevchilds $cmdline) fi + if strstr "$cmdline" noiswmd; then + /sbin/udevadm control --env=rd_NO_MDIMSM=1 + fi /sbin/udevadm control --env=STARTUP=1 @@ -301,20 +314,26 @@ if [ -f "/sys/class/tty/console/uevent" ]; then echo "Triggering Rest" fi - /sbin/udevadm trigger + /sbin/udevadm trigger --action=add ret=$[$ret + $?] wait_for_queue $udevtimeout ret=$[$ret + $?] wait + ret=$[$ret + $?] /sbin/udevadm control --env=STARTUP= + # touch all device files for timezone glitches + # "find" is in /usr/bin and might not be available + if [ -f /etc/sysconfig/clock ]; then + . /etc/sysconfig/clock + [[ "$UTC" == "false" || "$UTC" == "no" ]] \ + && touch_recursive /dev > "$udev_root/null" 2>&1 + fi else echo -n " kernel too old for this udev version " /sbin/udevd -d $UDEV_OPTS ret=10 - fi -ret=$[$ret + $?] [ $ret -eq 0 ] && success $"$STRING" || failure $"$STRING" echo exit 0 diff --git a/udev-145.tar.bz2.sign b/udev-145.tar.bz2.sign deleted file mode 100644 index 23c18c4..0000000 --- a/udev-145.tar.bz2.sign +++ /dev/null @@ -1,8 +0,0 @@ ------BEGIN PGP SIGNATURE----- -Version: GnuPG v1.4.9 (GNU/Linux) -Comment: See http://www.kernel.org/signature.html for info - -iD8DBQBKWxhnyGugalF9Dw4RAvvjAJ9ed+RMRi8gXcFyTPxXsHZpbLSROgCfdpCc -lr5nSwsGGO9e0+wBbD7WDoc= -=5/z0 ------END PGP SIGNATURE----- diff --git a/udev-151-gperf.patch b/udev-151-gperf.patch new file mode 100644 index 0000000..db93ba7 --- /dev/null +++ b/udev-151-gperf.patch @@ -0,0 +1,13 @@ +diff -up udev-151/extras/keymap/keys-from-name.gperf udev-151/extras/keymap/keys-from-name +diff -up udev-151/Makefile.am.gperf udev-151/Makefile.am +--- udev-151/Makefile.am.gperf 2010-03-19 14:04:36.000000000 +0100 ++++ udev-151/Makefile.am 2010-03-19 14:04:52.000000000 +0100 +@@ -550,7 +550,7 @@ extras/keymap/keys-from-name.gperf: extr + $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct key { const char* name; unsigned short id; };"; print "%null-strings"; print "%%";} { print $$1 ", " $$1 }' < $< > $@ + + extras/keymap/keys-from-name.h: extras/keymap/keys-from-name.gperf Makefile +- $(AM_V_GEN)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_key -H hash_key_name -p -C < $< > $@ ++ $(AM_V_GEN)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_key -H hash_key_name -p -C -D < $< > $@ + + extras/keymap/keys-to-name.h: extras/keymap/keys.txt Makefile + $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const key_names[KEY_CNT] = { "} { print "[" $$1 "] = \"" $$1 "\"," } END{print "};"}' < $< > $@ diff --git a/udev-151-virtio.patch b/udev-151-virtio.patch new file mode 100644 index 0000000..53bbef6 --- /dev/null +++ b/udev-151-virtio.patch @@ -0,0 +1,30 @@ +From 764304885705e51ef3eb1d078eed3cf6604c4684 Mon Sep 17 00:00:00 2001 +From: Amit Shah +Date: Fri, 26 Feb 2010 14:02:51 +0530 +Subject: [PATCH] Fix virtio-ports rule to use $attr instead of $ATTR + +Newer udev versions don't understand $ATTR. + +Signed-off-by: Amit Shah +--- + rules/rules.d/50-udev-default.rules | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +Changed by Harald Hoyer + +diff --git a/rules/rules.d/50-udev-default.rules b/rules/rules.d/50-udev-default.rules +index f8556d1..da1535f 100644 +--- a/rules/rules.d/50-udev-default.rules ++++ b/rules/rules.d/50-udev-default.rules +@@ -18,7 +18,7 @@ KERNEL=="mwave", GROUP="dialout" + KERNEL=="hvc*|hvsi*", GROUP="dialout" + + # virtio serial / console ports +-KERNEL=="vport*", SYMLINK+="virtio-ports/$attr{name}" ++KERNEL=="vport*", ATTR{name}=="?*", SYMLINK+="virtio-ports/$attr{name}" + + # mem + KERNEL=="null|zero|full|random|urandom", MODE="0666" +-- +1.6.2.5 + diff --git a/udev-153-cdrom_id-backport.patch b/udev-153-cdrom_id-backport.patch new file mode 100644 index 0000000..46e0a5b --- /dev/null +++ b/udev-153-cdrom_id-backport.patch @@ -0,0 +1,246 @@ +diff -ur udev-153-orig/extras/cdrom_id/cdrom_id.c udev-153/extras/cdrom_id/cdrom_id.c +--- udev-153-orig/extras/cdrom_id/cdrom_id.c 2010-04-17 19:29:58.000000000 +0200 ++++ udev-153/extras/cdrom_id/cdrom_id.c 2010-08-31 10:35:41.000000000 +0200 +@@ -85,6 +85,8 @@ + static unsigned int cd_media_dvd_rom = 0; + static unsigned int cd_media_dvd_r = 0; + static unsigned int cd_media_dvd_rw = 0; ++static unsigned int cd_media_dvd_rw_ro = 0; /* restricted overwrite mode */ ++static unsigned int cd_media_dvd_rw_seq = 0; /* sequential mode */ + static unsigned int cd_media_dvd_ram = 0; + static unsigned int cd_media_dvd_plus_r = 0; + static unsigned int cd_media_dvd_plus_rw = 0; +@@ -348,6 +350,39 @@ + return 0; + } + ++static int cd_profiles_old_mmc(struct udev *udev, int fd) ++{ ++ struct scsi_cmd sc; ++ int err; ++ ++ unsigned char header[32]; ++ ++ scsi_cmd_init(udev, &sc, header, sizeof(header)); ++ scsi_cmd_set(udev, &sc, 0, 0x51); ++ scsi_cmd_set(udev, &sc, 8, sizeof(header)); ++ scsi_cmd_set(udev, &sc, 9, 0); ++ err = scsi_cmd_run(udev, &sc, fd, header, sizeof(header)); ++ if ((err != 0)) { ++ info_scsi_cmd_err(udev, "READ DISC INFORMATION", err); ++ info(udev, "no current profile, assuming no media\n"); ++ return -1; ++ }; ++ ++ cd_media = 1; ++ ++ if (header[2] & 16) { ++ cd_media_cd_rw = 1; ++ info(udev, "profile 0x0a media_cd_rw\n"); ++ } else if ((header[2] & 3) < 2 && cd_cd_r) { ++ cd_media_cd_r = 1; ++ info(udev, "profile 0x09 media_cd_r\n"); ++ } else { ++ cd_media_cd_rom = 1; ++ info(udev, "profile 0x08 media_cd_rom\n"); ++ } ++ return 0; ++} ++ + static int cd_profiles(struct udev *udev, int fd) + { + struct scsi_cmd sc; +@@ -365,6 +400,12 @@ + err = scsi_cmd_run(udev, &sc, fd, features, sizeof(features)); + if ((err != 0)) { + info_scsi_cmd_err(udev, "GET CONFIGURATION", err); ++ /* handle pre-MMC2 drives which do not support GET CONFIGURATION */ ++ if (SK(err) == 0x5 && ASC(err) == 0x20) { ++ info(udev, "drive is pre-MMC2 and does not support 46h get configuration command\n"); ++ info(udev, "trying to work around the problem\n"); ++ return cd_profiles_old_mmc(udev, fd); ++ } + return -1; + } + +@@ -440,10 +481,16 @@ + cd_media_dvd_ram = 1; + break; + case 0x13: ++ info(udev, "profile 0x%02x media_dvd_rw_ro\n", cur_profile); ++ cd_media = 1; ++ cd_media_dvd_rw = 1; ++ cd_media_dvd_rw_ro = 1; ++ break; + case 0x14: +- info(udev, "profile 0x%02x media_dvd_rw\n", cur_profile); ++ info(udev, "profile 0x%02x media_dvd_rw_seq\n", cur_profile); + cd_media = 1; + cd_media_dvd_rw = 1; ++ cd_media_dvd_rw_seq = 1; + break; + case 0x1B: + info(udev, "profile 0x%02x media_dvd_plus_r\n", cur_profile); +@@ -527,12 +574,126 @@ + + cd_media = 1; + info(udev, "disk type %02x\n", header[8]); ++ info(udev, "hardware reported media status: %s\n", media_status[header[2] & 3]); + + /* exclude plain CDROM, some fake cdroms return 0 for "blank" media here */ + if (!cd_media_cd_rom) + cd_media_state = media_status[header[2] & 3]; + +- if ((header[2] & 3) != 2) ++ /* fresh DVD-RW in restricted overwite mode reports itself as ++ * "appendable"; change it to "blank" to make it consistent with what ++ * gets reported after blanking, and what userspace expects */ ++ if (cd_media_dvd_rw_ro && (header[2] & 3) == 1) ++ cd_media_state = media_status[0]; ++ ++ /* DVD+RW discs (and DVD-RW in restricted mode) once formatted are ++ * always "complete", DVD-RAM are "other" or "complete" if the disc is ++ * write protected; we need to check the contents if it is blank */ ++ if ((cd_media_dvd_rw_ro || cd_media_dvd_plus_rw || cd_media_dvd_plus_rw_dl || cd_media_dvd_ram) && (header[2] & 3) > 1) { ++ unsigned char buffer[32 * 2048]; ++ unsigned char result, len; ++ int block, offset; ++ ++ if (cd_media_dvd_ram) { ++ /* a write protected dvd-ram may report "complete" status */ ++ ++ unsigned char dvdstruct[8]; ++ unsigned char format[12]; ++ ++ scsi_cmd_init(udev, &sc, dvdstruct, sizeof(dvdstruct)); ++ scsi_cmd_set(udev, &sc, 0, 0xAD); ++ scsi_cmd_set(udev, &sc, 7, 0xC0); ++ scsi_cmd_set(udev, &sc, 9, sizeof(dvdstruct)); ++ scsi_cmd_set(udev, &sc, 11, 0); ++ err = scsi_cmd_run(udev, &sc, fd, dvdstruct, sizeof(dvdstruct)); ++ if ((err != 0)) { ++ info_scsi_cmd_err(udev, "READ DVD STRUCTURE", err); ++ return -1; ++ } ++ if (dvdstruct[4] & 0x02) { ++ cd_media_state = media_status[2]; ++ info(udev, "write-protected DVD-RAM media inserted\n"); ++ goto determined; ++ } ++ ++ /* let's make sure we don't try to read unformatted media */ ++ scsi_cmd_init(udev, &sc, format, sizeof(format)); ++ scsi_cmd_set(udev, &sc, 0, 0x23); ++ scsi_cmd_set(udev, &sc, 8, sizeof(format)); ++ scsi_cmd_set(udev, &sc, 9, 0); ++ err = scsi_cmd_run(udev, &sc, fd, format, sizeof(format)); ++ if ((err != 0)) { ++ info_scsi_cmd_err(udev, "READ DVD FORMAT CAPACITIES", err); ++ return -1; ++ } ++ ++ len = format[3]; ++ if (len & 7 || len < 16) { ++ info(udev, "invalid format capacities length\n"); ++ return -1; ++ } ++ ++ switch(format[8] & 3) { ++ case 1: ++ info(udev, "unformatted DVD-RAM media inserted\n"); ++ /* This means that last format was interrupted ++ * or failed, blank dvd-ram discs are factory ++ * formatted. Take no action here as it takes ++ * quite a while to reformat a dvd-ram and it's ++ * not automatically started */ ++ goto determined; ++ ++ case 2: ++ info(udev, "formatted DVD-RAM media inserted\n"); ++ break; ++ ++ case 3: ++ cd_media = 0; //return no media ++ info(udev, "format capacities returned no media\n"); ++ return -1; ++ } ++ } ++ ++ /* Take a closer look at formatted media (unformatted DVD+RW ++ * has "blank" status", DVD-RAM was examined earlier) and check ++ * for ISO and UDF PVDs or a fs superblock presence and do it ++ * in one ioctl (we need just sectors 0 and 16) */ ++ scsi_cmd_init(udev, &sc, buffer, sizeof(buffer)); ++ scsi_cmd_set(udev, &sc, 0, 0x28); ++ scsi_cmd_set(udev, &sc, 5, 0); ++ scsi_cmd_set(udev, &sc, 8, 32); ++ scsi_cmd_set(udev, &sc, 9, 0); ++ err = scsi_cmd_run(udev, &sc, fd, buffer, sizeof(buffer)); ++ if ((err != 0)) { ++ info_scsi_cmd_err(udev, "READ FIRST 32 BLOCKS", err); ++ return -1; ++ } ++ ++ /* if any non-zero data is found in sector 16 (iso and udf) or ++ * eventually 0 (fat32 boot sector, ext2 superblock, etc), disc ++ * is assumed non-blank */ ++ result = 0; ++ ++ for (block = 32768; block >= 0 && !result; block -= 32768) { ++ offset = block; ++ while (offset < (block + 2048) && !result) { ++ result = buffer [offset]; ++ offset++; ++ } ++ } ++ ++ if (!result) { ++ cd_media_state = media_status[0]; ++ info(udev, "no data in blocks 0 or 16, assuming blank\n"); ++ } else { ++ info(udev, "data in blocks 0 or 16, assuming complete\n"); ++ } ++ } ++ ++determined: ++ /* "other" is e. g. DVD-RAM, can't append sessions there; DVDs in ++ * restricted overwrite mode can never append, only in sequential mode */ ++ if ((header[2] & 3) < 2 && !cd_media_dvd_rw_ro) + cd_media_session_next = header[10] << 8 | header[5]; + cd_media_session_count = header[9] << 8 | header[4]; + cd_media_track_count = header[11] << 8 | header[6]; +@@ -710,13 +871,11 @@ + if (cd_profiles(udev, fd) < 0) + goto print; + +- /* get writable media state */ +- if (cd_media_info(udev, fd) < 0) +- goto print; +- + /* get session/track info */ +- if (cd_media_toc(udev, fd) < 0) +- goto print; ++ cd_media_toc(udev, fd); ++ ++ /* get writable media state */ ++ cd_media_info(udev, fd); + + print: + printf("ID_CDROM=1\n"); +@@ -810,14 +969,14 @@ + printf("ID_CDROM_MEDIA_SESSION_NEXT=%d\n", cd_media_session_next); + if (cd_media_session_count > 0) + printf("ID_CDROM_MEDIA_SESSION_COUNT=%d\n", cd_media_session_count); ++ if (cd_media_session_count > 1 && cd_media_session_last_offset > 0) ++ printf("ID_CDROM_MEDIA_SESSION_LAST_OFFSET=%llu\n", cd_media_session_last_offset); + if (cd_media_track_count > 0) + printf("ID_CDROM_MEDIA_TRACK_COUNT=%d\n", cd_media_track_count); + if (cd_media_track_count_audio > 0) + printf("ID_CDROM_MEDIA_TRACK_COUNT_AUDIO=%d\n", cd_media_track_count_audio); + if (cd_media_track_count_data > 0) + printf("ID_CDROM_MEDIA_TRACK_COUNT_DATA=%d\n", cd_media_track_count_data); +- if (cd_media_session_last_offset > 0) +- printf("ID_CDROM_MEDIA_SESSION_LAST_OFFSET=%llu\n", cd_media_session_last_offset); + exit: + if (fd >= 0) + close(fd); diff --git a/udev-153-changer.patch b/udev-153-changer.patch new file mode 100644 index 0000000..a80888c --- /dev/null +++ b/udev-153-changer.patch @@ -0,0 +1,25 @@ +diff -up udev-153/rules/redhat/40-redhat.rules.changer udev-153/rules/redhat/40-redhat.rules +--- udev-153/rules/redhat/40-redhat.rules.changer 2010-08-04 15:32:00.000000000 +0200 ++++ udev-153/rules/redhat/40-redhat.rules 2010-08-04 15:35:27.000000000 +0200 +@@ -5,17 +5,17 @@ KERNEL=="hd*[0-9]", ATTRS{media}=="flopp + + KERNEL=="fw*", PROGRAM="fw_unit_symlinks.sh %k %n", SYMLINK+="$result" + +-ACTION=="add", KERNEL=="sg[0-9]*", SUBSYSTEM=="scsi_device", ATTRS{type}=="3|6", SYMLINK+="scanner scanner-%k", MODE="0660" ++ACTION=="add", KERNEL=="sg[0-9]*", SUBSYSTEM=="scsi_generic", ATTRS{type}=="3|6", SYMLINK+="scanner scanner-%k", MODE="0660" + +-ACTION=="add", KERNEL=="sg[0-9]*", SUBSYSTEM=="scsi_device", ATTRS{type}=="8", SYMLINK+="changer changer-%k", MODE="0660", GROUP="disk" ++ACTION=="add", KERNEL=="sg[0-9]*", SUBSYSTEM=="scsi_generic", ATTRS{type}=="8", SYMLINK+="changer changer-%k", MODE="0660", GROUP="disk" + + SUBSYSTEM=="usb", KERNEL=="sd*", ATTRS{bInterfaceClass}=="08", ATTRS{bInterfaceSubClass}=="04", GROUP="floppy", MODE="0660", SYMLINK+="floppy floppy-%k" + + KERNEL=="fd[0-9]*", SYMLINK+="floppy floppy-%k" + +-ACTION=="add", SUBSYSTEM=="scsi_device", ATTRS{type}=="0|7|14", \ ++ACTION=="add", SUBSYSTEM=="scsi_generic", ATTRS{type}=="0|7|14", \ + RUN+="/sbin/modprobe sd_mod" +-ACTION=="add", SUBSYSTEM=="scsi_device", ATTRS{type}=="[45]", \ ++ACTION=="add", SUBSYSTEM=="scsi_generic", ATTRS{type}=="[45]", \ + RUN+="/sbin/modprobe sr_mod" + + KERNEL=="vcs", OWNER="vcsa", GROUP="tty" diff --git a/udev-153-keymap-backport.patch b/udev-153-keymap-backport.patch new file mode 100644 index 0000000..4f97c2f --- /dev/null +++ b/udev-153-keymap-backport.patch @@ -0,0 +1,194 @@ +diff -urN udev-153-orig/extras/keymap/95-keyboard-force-release.rules udev-153/extras/keymap/95-keyboard-force-release.rules +--- udev-153-orig/extras/keymap/95-keyboard-force-release.rules 2010-09-21 13:52:31.000000000 +0200 ++++ udev-153/extras/keymap/95-keyboard-force-release.rules 2010-08-04 14:23:27.000000000 +0200 +@@ -19,7 +19,7 @@ + ENV{DMI_VENDOR}="$attr{[dmi/id]sys_vendor}" + + +-ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*N128*|*N130*|*N140*|*N210*|*SR70S/SR71S*|*Q210/P210*", RUN+="keyboard-force-release.sh $devpath samsung-other" ++ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*E252*|*N120*|*N128*|*N130*|*N140*|*N148/N208*|*N150*|*N150/N210/N220*|*N220*|*N308*|*N310*|*N510*|*NB30*|*NC10/N110*|*ND10*|*Q210/P210*|*R410P*|*R425/R525*|*R428/P428*|*R460*|*R463*|*R468/R418*|*R480/R431/R481*|*R509*|*R518*|*R519/R719*|*R520/R522/R620*|*R528/R728*|*R530/R730*|*R530/R730/P590*|*R560*|*R580*|*R580/R590*|*R59/R60/R61*|*R59P/R60P/R61P*|*R710*|*R720*|*R780/R778*|*SR58P*|*SR700*|*SR70S/SR71S*|*SX22S*|*X118*|*X120*|*X460*", RUN+="keyboard-force-release.sh $devpath samsung-other" + + ENV{DMI_VENDOR}=="Dell Inc.", ATTR{[dmi/id]product_name}=="Studio 1557|Studio 1558", RUN+="keyboard-force-release.sh $devpath common-volume-keys" + +@@ -29,4 +29,10 @@ + + ENV{DMI_VENDOR}=="MTC", ATTR{[dmi/id]product_version}=="A0", RUN+="keyboard-force-release.sh $devpath common-volume-keys" + ++ENV{DMI_VENDOR}=="PEGATRON CORP.", ATTR{[dmi/id]product_name}=="Spring Peak", RUN+="keyboard-force-release.sh $devpath common-volume-keys" ++ ++ENV{DMI_VENDOR}=="TOSHIBA", ATTR{[dmi/id]product_name}=="Satellite U300|Satellite Pro U300|Satellite U305", RUN+="keyboard-force-release.sh $devpath common-volume-keys" ++ ++ENV{DMI_VENDOR}=="Viooo Corporation", ATTR{[dmi/id]product_name}=="PT17", RUN+="keyboard-force-release.sh $devpath common-volume-keys" ++ + LABEL="force_release_end" +diff -urN udev-153-orig/extras/keymap/95-keymap.rules udev-153/extras/keymap/95-keymap.rules +--- udev-153-orig/extras/keymap/95-keymap.rules 2010-09-21 13:52:31.000000000 +0200 ++++ udev-153/extras/keymap/95-keymap.rules 2010-09-21 12:02:18.000000000 +0200 +@@ -21,7 +21,11 @@ + + ENV{ID_VENDOR}=="Logitech*", ATTRS{name}=="Logitech USB Multimedia Keyboard", RUN+="keymap $name logitech-wave" + ENV{ID_VENDOR}=="Logitech*", ATTRS{name}=="Logitech USB Receiver", RUN+="keymap $name logitech-wave-cordless" ++# Logitech Cordless Wave Pro looks slightly weird; some hotkeys are coming through the mouse interface ++ENV{ID_VENDOR_ID}=="046d", ENV{ID_MODEL_ID}=="c529", ATTRS{name}=="Logitech USB Receiver", RUN+="keymap $name logitech-wave-pro-cordless" ++ + ENV{ID_VENDOR}=="Lite-On_Technology_Corp*", ATTRS{name}=="Lite-On Technology Corp. ThinkPad USB Keyboard with TrackPoint", RUN+="keymap $name lenovo-thinkpad-usb-keyboard-trackpoint" ++ENV{ID_VENDOR_ID}=="04b3", ENV{ID_MODEL_ID}=="301[89]", RUN+="keymap $name ibm-thinkpad-usb-keyboard-trackpoint" + + GOTO="keyboard_end" + +@@ -37,11 +41,12 @@ + + ENV{DMI_VENDOR}=="IBM*", KERNELS=="input*", ATTRS{name}=="ThinkPad Extra Buttons", RUN+="keymap $name module-ibm" + ENV{DMI_VENDOR}=="LENOVO*", KERNELS=="input*", ATTRS{name}=="ThinkPad Extra Buttons", RUN+="keymap $name module-lenovo" ++ENV{DMI_VENDOR}=="LENOVO*", KERNELS=="input*", ATTRS{name}=="Lenovo ThinkPad SL Series extra buttons", RUN+="keymap $name 0x0E bluetooth" + ENV{DMI_VENDOR}=="ASUS*", KERNELS=="input*", ATTRS{name}=="Asus Extra Buttons", ATTR{[dmi/id]product_name}=="W3J", RUN+="keymap $name module-asus-w3j" + ENV{DMI_VENDOR}=="Sony*", KERNELS=="input*", ATTRS{name}=="Sony Vaio Keys", RUN+="keymap $name module-sony" + + # Older Vaios have some different keys +-ENV{DMI_VENDOR}=="Sony*", ATTR{[dmi/id]product_name}=="*PCG-C1*|*PCG-K25*|*PCG-F1*|*PCG-F2*|*PCG-F3*|*PCG-F4*|*PCG-F5*|*PCG-F6*|*PCG-FX*|*PCG-FRV*|*PCG-GR*|*PCG-TR*|*PCG-NV*|*PCG-Z*|*VGN-S360*|*VGN-SZ2HP_B*", ATTRS{name}=="Sony Vaio Keys", RUN+="keymap $name module-sony-old" ++ENV{DMI_VENDOR}=="Sony*", ATTR{[dmi/id]product_name}=="*PCG-C1*|*PCG-K25*|*PCG-F1*|*PCG-F2*|*PCG-F3*|*PCG-F4*|*PCG-F5*|*PCG-F6*|*PCG-FX*|*PCG-FRV*|*PCG-GR*|*PCG-TR*|*PCG-NV*|*PCG-Z*|*VGN-S360*", ATTRS{name}=="Sony Vaio Keys", RUN+="keymap $name module-sony-old" + + # + # The following rules belong to standard i8042 AT keyboard with high key codes. +@@ -53,19 +58,22 @@ + LABEL="keyboard_vendorcheck" + + ENV{DMI_VENDOR}=="Dell*", RUN+="keymap $name dell" +-ENV{DMI_VENDOR}=="Dell*", ATTR{[dmi/id]product_name}=="Inspiron 1011", RUN+="keymap $name 0x84 wlan" ++ENV{DMI_VENDOR}=="Dell*", ATTR{[dmi/id]product_name}=="Inspiron 910|Inspiron 1010|Inspiron 1011|Inspiron 1012|Inspiron 1110|Inspiron 1210", RUN+="keymap $name 0x84 wlan" + + ENV{DMI_VENDOR}=="Compaq*", ATTR{[dmi/id]product_name}=="*E500*|*Evo N*", RUN+="keymap $name compaq-e_evo" + + ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="*3000*", RUN+="keymap $name lenovo-3000" + ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="ThinkPad X6*", ATTR{[dmi/id]product_version}=="* Tablet" RUN+="keymap $name lenovo-thinkpad_x6_tablet" + ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="ThinkPad X200 Tablet*", ATTR{[dmi/id]product_version}=="* Tablet" RUN+="keymap $name lenovo-thinkpad_x200_tablet" ++ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_version}=="*IdeaPad*", RUN+="keymap $name lenovo-ideapad" ++ENV{DMI_VENDOR}=="LENOVO*", ATTR{[dmi/id]product_name}=="S10-*", RUN+="keymap $name lenovo-ideapad" ++ENV{DMI_VENDOR}=="LENOVO", ATTR{[dmi/id]product_version}=="*IdeaPad Y550*", RUN+="keymap $name 0x95 media 0xA3 play" + + ENV{DMI_VENDOR}=="Hewlett-Packard*", RUN+="keymap $name hewlett-packard" + ENV{DMI_VENDOR}=="Hewlett-Packard*", ATTR{[dmi/id]product_name}=="*[tT][aA][bB][lL][eE][tT]*", RUN+="keymap $name hewlett-packard-tablet" + ENV{DMI_VENDOR}=="Hewlett-Packard*", ATTR{[dmi/id]product_name}=="*[pP][aA][vV][iI][lL][iI][oO][nN]*", RUN+="keymap $name hewlett-packard-pavilion" + ENV{DMI_VENDOR}=="Hewlett-Packard*", ATTR{[dmi/id]product_name}=="*Compaq*|*EliteBook*|*2230s*", RUN+="keymap $name hewlett-packard-compaq_elitebook" +-ENV{DMI_VENDOR}=="Hewlett-Packard*", ATTR{[dmi/id]product_name}=="*2510p*|*2530p*", RUN+="keymap $name hewlett-packard-2510p_2530p" ++ENV{DMI_VENDOR}=="Hewlett-Packard*", ATTR{[dmi/id]product_name}=="*2510p*|*2530p*|HP G60 Notebook PC", RUN+="keymap $name hewlett-packard-2510p_2530p" + ENV{DMI_VENDOR}=="Hewlett-Packard*", ATTR{[dmi/id]product_name}=="*[tT][xX]2*", RUN+="keymap $name hewlett-packard-tx2" + ENV{DMI_VENDOR}=="Hewlett-Packard", ATTR{[dmi/id]product_name}=="Presario 2100*", RUN+="keymap $name hewlett-packard-presario-2100" + # HP Pavillion dv6315ea has empty DMI_VENDOR +@@ -77,7 +85,8 @@ + ENV{DMI_VENDOR}=="Acer*", RUN+="keymap $name acer" + ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="Extensa*", ATTR{[dmi/id]product_name}=="*5210*|*5220*|*5610*|*5620*|*5720*", RUN+="keymap $name 0xEE screenlock" + ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="TravelMate*C300*", RUN+="keymap $name acer-travelmate_c300" +-ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="TravelMate*6292*|TravelMate*8471*|Aspire 1810T*|AO751h|AO531h", RUN+="keymap $name 0xD9 bluetooth" ++ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="TravelMate*6292*|TravelMate*8471*|TravelMate*4720*|Aspire 1810T*|AO751h|AO531h", RUN+="keymap $name 0xD9 bluetooth" ++ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="TravelMate*4720*", RUN+="keymap $name 0xB2 www 0xEE screenlock" + ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="TravelMate 6593|Aspire 1640", RUN+="keymap $name 0xB2 www 0xEE screenlock" + ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="Aspire 6920", RUN+="keymap $name acer-aspire_6920" + ENV{DMI_VENDOR}=="Acer*", ATTR{[dmi/id]product_name}=="Aspire 5920G", RUN+="keymap $name acer-aspire_5920g" +@@ -110,7 +119,7 @@ + + ENV{DMI_VENDOR}=="MAXDATA", ATTR{[dmi/id]product_name}=="Pro 7000*", RUN+="keymap $name maxdata-pro_7000" + +-ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*NC10*|*NC20*|*N128*|*N130*|*N210*|*SP55S*|*SQ45S70S*|*SX60P*|*SX22S*|*SX30S*|*R59P/R60P/R61P*|*SR70S/SR71S*|*Q210*|*Q310*|*X05*|*P560*|*R560*", RUN+="keymap $name samsung-other" ++ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", RUN+="keymap $name samsung-other" + ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*SX20S*", RUN+="keymap $name samsung-sx20s" + ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="SQ1US", RUN+="keymap $name samsung-sq1us" + +@@ -120,6 +129,8 @@ + + ENV{DMI_VENDOR}=="OQO Inc.*", ATTR{[dmi/id]product_name}=="OQO Model 2*", RUN+="keymap $name oqo-model2" + ++ENV{DMI_VENDOR}=="ONKYO CORPORATION", ATTR{[dmi/id]product_name}=="ONKYOPC", RUN+="keymap $name onkyo" ++ + ENV{DMI_VENDOR}=="ASUS", RUN+="keymap $name asus" + + ENV{DMI_VENDOR}=="VIA", ATTR{[dmi/id]product_name}=="K8N800", ATTR{[dmi/id]product_version}=="VT8204B", RUN+="keymap $name 0x81 prog1" +diff -urN udev-153-orig/extras/keymap/findkeyboards udev-153/extras/keymap/findkeyboards +--- udev-153-orig/extras/keymap/findkeyboards 2009-12-15 12:49:25.000000000 +0100 ++++ udev-153/extras/keymap/findkeyboards 2010-07-08 11:37:47.000000000 +0200 +@@ -34,6 +34,8 @@ + # modules + module=`udevadm trigger --verbose --dry-run --subsystem-match=input --attr-match=name='*Extra Buttons'` + module="$module ++`udevadm trigger --verbose --dry-run --subsystem-match=input --attr-match=name='*extra buttons'`" ++ module="$module + `udevadm trigger --verbose --dry-run --subsystem-match=input --attr-match=name='Sony Vaio Keys'`" + for m in $module; do + evdev=`ls -d $m/event* 2>/dev/null` +diff -urN udev-153-orig/extras/keymap/.gitignore udev-153/extras/keymap/.gitignore +--- udev-153-orig/extras/keymap/.gitignore 1970-01-01 01:00:00.000000000 +0100 ++++ udev-153/extras/keymap/.gitignore 2010-03-18 16:44:52.000000000 +0100 +@@ -0,0 +1,6 @@ ++keymap ++keys-from-name.gperf ++keys-from-name.h ++keys-to-name.h ++keys.txt ++ +diff -urN udev-153-orig/extras/keymap/keymaps/ibm-thinkpad-usb-keyboard-trackpoint udev-153/extras/keymap/keymaps/ibm-thinkpad-usb-keyboard-trackpoint +--- udev-153-orig/extras/keymap/keymaps/ibm-thinkpad-usb-keyboard-trackpoint 1970-01-01 01:00:00.000000000 +0100 ++++ udev-153/extras/keymap/keymaps/ibm-thinkpad-usb-keyboard-trackpoint 2010-07-07 10:58:29.000000000 +0200 +@@ -0,0 +1,7 @@ ++0x900f0 screenlock ++0x900f1 wlan ++0x900f2 switchvideomode ++0x900f3 suspend ++0x900f4 brightnessup ++0x900f5 brightnessdown ++0x900f8 zoom +diff -urN udev-153-orig/extras/keymap/keymaps/lenovo-ideapad udev-153/extras/keymap/keymaps/lenovo-ideapad +--- udev-153-orig/extras/keymap/keymaps/lenovo-ideapad 1970-01-01 01:00:00.000000000 +0100 ++++ udev-153/extras/keymap/keymaps/lenovo-ideapad 2010-08-17 16:31:27.000000000 +0200 +@@ -0,0 +1,7 @@ ++# Key codes observed on S10-3, assumed valid on other IdeaPad models ++0x81 rfkill # does nothing in BIOS ++0x83 display_off # BIOS toggles screen state ++0xB9 brightnessup # does nothing in BIOS ++0xBA brightnessdown # does nothing in BIOS ++0xF1 camera # BIOS toggles camera power ++0xf2 unknown # trackpad enable/disable (does nothing in BIOS) +diff -urN udev-153-orig/extras/keymap/keymaps/logitech-wave-pro-cordless udev-153/extras/keymap/keymaps/logitech-wave-pro-cordless +--- udev-153-orig/extras/keymap/keymaps/logitech-wave-pro-cordless 1970-01-01 01:00:00.000000000 +0100 ++++ udev-153/extras/keymap/keymaps/logitech-wave-pro-cordless 2010-07-07 10:58:29.000000000 +0200 +@@ -0,0 +1,12 @@ ++0xC01B6 camera ++0xC0183 media ++0xC0184 wordprocessor ++0xC0186 spreadsheet ++0xC018E calendar ++0xC0223 homepage ++0xC01BC messenger ++0xC018A mail ++0xC0221 search ++0xC00B8 ejectcd ++0xC022D zoomin ++0xC022E zoomout +diff -urN udev-153-orig/extras/keymap/keymaps/micro-star udev-153/extras/keymap/keymaps/micro-star +--- udev-153-orig/extras/keymap/keymaps/micro-star 2009-12-03 13:45:03.000000000 +0100 ++++ udev-153/extras/keymap/keymaps/micro-star 2010-06-11 10:52:56.000000000 +0200 +@@ -6,6 +6,7 @@ + 0xE2 bluetooth # satellite dish2 + 0xE4 f22 # Fn-F3 Touchpad disable + 0xEC email # envelope button ++0xEE camera # Fn-F6 camera disable + 0xF6 wlan # satellite dish1 + 0xF7 brightnessdown # Fn-F4 + 0xF8 brightnessup # Fn-F5 +diff -urN udev-153-orig/extras/keymap/keymaps/onkyo udev-153/extras/keymap/keymaps/onkyo +--- udev-153-orig/extras/keymap/keymaps/onkyo 1970-01-01 01:00:00.000000000 +0100 ++++ udev-153/extras/keymap/keymaps/onkyo 2010-08-31 10:35:41.000000000 +0200 +@@ -0,0 +1,14 @@ ++0xA0 mute # Fn+D ++0xAE volumedown # Fn+F ++0xB0 volumeup # Fn+G ++0xDF sleep # Fn+W ++0xE0 bluetooth # Fn+H ++0xE2 cyclewindows # Fn+Esc ++0xEE battery # Fn+Q ++0xF0 media # Fn+R ++0xF5 switchvideomode # Fn+E ++0xF6 camera # Fn+T ++0xF7 f22 # Fn+Y (touchpad toggle) ++0xF8 brightnessup # Fn+S ++0xF9 brightnessdown # Fn+A ++0xFB wlan # Fn+J diff --git a/udev-153-n210.patch b/udev-153-n210.patch new file mode 100644 index 0000000..f7f3652 --- /dev/null +++ b/udev-153-n210.patch @@ -0,0 +1,24 @@ +diff -up udev-153/extras/keymap/95-keyboard-force-release.rules.n210 udev-153/extras/keymap/95-keyboard-force-release.rules +--- udev-153/extras/keymap/95-keyboard-force-release.rules.n210 2010-08-04 15:55:56.000000000 +0200 ++++ udev-153/extras/keymap/95-keyboard-force-release.rules 2010-08-04 15:57:54.000000000 +0200 +@@ -19,7 +19,7 @@ DRIVER!="atkbd", GOTO="force_release_end + ENV{DMI_VENDOR}="$attr{[dmi/id]sys_vendor}" + + +-ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*N130*|*N140*|*SR70S/SR71S*|*Q210/P210*", RUN+="keyboard-force-release.sh $devpath samsung-other" ++ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*N128*|*N130*|*N140*|*N210*|*SR70S/SR71S*|*Q210/P210*", RUN+="keyboard-force-release.sh $devpath samsung-other" + + ENV{DMI_VENDOR}=="Dell Inc.", ATTR{[dmi/id]product_name}=="Studio 1557|Studio 1558", RUN+="keyboard-force-release.sh $devpath common-volume-keys" + +diff -up udev-153/extras/keymap/95-keymap.rules.n210 udev-153/extras/keymap/95-keymap.rules +--- udev-153/extras/keymap/95-keymap.rules.n210 2010-08-04 15:57:23.000000000 +0200 ++++ udev-153/extras/keymap/95-keymap.rules 2010-08-04 15:57:52.000000000 +0200 +@@ -110,7 +110,7 @@ ENV{DMI_VENDOR}=="INVENTEC", ATTR{[dmi/i + + ENV{DMI_VENDOR}=="MAXDATA", ATTR{[dmi/id]product_name}=="Pro 7000*", RUN+="keymap $name maxdata-pro_7000" + +-ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*NC10*|*NC20*|*N130*|*SP55S*|*SQ45S70S*|*SX60P*|*SX22S*|*SX30S*|*R59P/R60P/R61P*|*SR70S/SR71S*|*Q210*|*Q310*|*X05*|*P560*|*R560*", RUN+="keymap $name samsung-other" ++ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*NC10*|*NC20*|*N128*|*N130*|*N210*|*SP55S*|*SQ45S70S*|*SX60P*|*SX22S*|*SX30S*|*R59P/R60P/R61P*|*SR70S/SR71S*|*Q210*|*Q310*|*X05*|*P560*|*R560*", RUN+="keymap $name samsung-other" + ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="*SX20S*", RUN+="keymap $name samsung-sx20s" + ENV{DMI_VENDOR}=="[sS][aA][mM][sS][uU][nN][gG]*", ATTR{[dmi/id]product_name}=="SQ1US", RUN+="keymap $name samsung-sq1us" + diff --git a/udev-153-trigger.patch b/udev-153-trigger.patch new file mode 100644 index 0000000..2bce982 --- /dev/null +++ b/udev-153-trigger.patch @@ -0,0 +1,22 @@ +diff --git a/udev/udevadm-trigger.c b/udev/udevadm-trigger.c +index 03aa534..dbcaee3 100644 +--- a/udev/udevadm-trigger.c ++++ b/udev/udevadm-trigger.c +@@ -110,7 +110,7 @@ int udevadm_trigger(struct udev *udev, int argc, char *argv[]) + TYPE_SUBSYSTEMS, + TYPE_FAILED, + } device_type = TYPE_DEVICES; +- const char *action = "change"; ++ const char *action = "add"; + struct udev_enumerate *udev_enumerate; + int rc = 0; + +@@ -184,7 +184,7 @@ int udevadm_trigger(struct udev *udev, int argc, char *argv[]) + " subsystems sys subsystems and drivers\n" + " failed trigger only the events which have been\n" + " marked as failed during a previous run\n" +- " --action= event action value, default is \"change\"\n" ++ " --action= event action value, default is \"add\"\n" + " --subsystem-match= trigger devices from a matching subsystem\n" + " --subsystem-nomatch= exclude devices from a matching subsystem\n" + " --attr-match=]> trigger devices with a matching attribute\n" diff --git a/udev-git484e1b2d11b9b89418589d885a625e647881933b.patch b/udev-git484e1b2d11b9b89418589d885a625e647881933b.patch new file mode 100644 index 0000000..38dfb40 --- /dev/null +++ b/udev-git484e1b2d11b9b89418589d885a625e647881933b.patch @@ -0,0 +1,27 @@ +commit 484e1b2d11b9b89418589d885a625e647881933b +Author: Kay Sievers +Date: Tue May 25 09:54:14 2010 +0200 + + rules: optical drives - use ID_CDROM_MEDIA_TRACK_COUNT_DATA + + We should not access non-data optical media, ans skip things + like blkid. It will cause errors for some drives. + + https://bugzilla.kernel.org/show_bug.cgi?id=15757 + +diff --git a/rules/rules.d/60-persistent-storage.rules b/rules/rules.d/60-persistent-storage.rules +index d9f8003..1f46041 100644 +--- a/rules/rules.d/60-persistent-storage.rules ++++ b/rules/rules.d/60-persistent-storage.rules +@@ -52,9 +52,9 @@ ENV{DEVTYPE}=="partition", ENV{ID_PATH}=="?*", SYMLINK+="disk/by-path/$env{ID_PA + ENV{DEVTYPE}=="disk", KERNEL!="sd*|sr*", ATTR{removable}=="1", GOTO="persistent_storage_end" + + # probe filesystem metadata of optical drives which have a media inserted +-KERNEL=="sr*", ENV{ID_CDROM_MEDIA}=="?*", ENV{ID_CDROM_MEDIA_SESSION_LAST_OFFSET}=="?*", IMPORT{program}="/sbin/blkid -o udev -p -u noraid -O $env{ID_CDROM_MEDIA_SESSION_LAST_OFFSET} $tempnode" ++KERNEL=="sr*", ENV{ID_CDROM_MEDIA_TRACK_COUNT_DATA}=="?*", ENV{ID_CDROM_MEDIA_SESSION_LAST_OFFSET}=="?*", IMPORT{program}="/sbin/blkid -o udev -p -u noraid -O $env{ID_CDROM_MEDIA_SESSION_LAST_OFFSET} $tempnode" + # single-session CDs do not have ID_CDROM_MEDIA_SESSION_LAST_OFFSET +-KERNEL=="sr*", ENV{ID_CDROM_MEDIA}=="?*", ENV{ID_CDROM_MEDIA_SESSION_LAST_OFFSET}=="", IMPORT{program}="/sbin/blkid -o udev -p -u noraid $tempnode" ++KERNEL=="sr*", ENV{ID_CDROM_MEDIA_TRACK_COUNT_DATA}=="?*", ENV{ID_CDROM_MEDIA_SESSION_LAST_OFFSET}=="", IMPORT{program}="/sbin/blkid -o udev -p -u noraid $tempnode" + + # probe filesystem metadata of disks + KERNEL!="sr*", IMPORT{program}="/sbin/blkid -o udev -p $tempnode" diff --git a/udev-post.init b/udev-post.init index f040950..89df663 100644 --- a/udev-post.init +++ b/udev-post.init @@ -26,7 +26,7 @@ case "$1" in [ -w /var/lock/subsys ] || exit 4 STRING=$"Retrigger failed udev events" echo -n $STRING - /sbin/udevadm trigger --type=failed + /sbin/udevadm trigger --type=failed --action=add success "$STRING" echo @@ -58,8 +58,8 @@ case "$1" in STRING=$"Generating udev makedev cache file" MAKEDEV="/sbin/MAKEDEV" USE_MD5="false" - [ -x /usr/bin/md5sum -a "$UDEV_USE_MAKEDEV_CACHE" == "yes" ] && USE_MD5="true" - if [ "$USE_MD5" == "true" -a -x "$MAKEDEV" ]; then + [[ "$UDEV_USE_MAKEDEV_CACHE" == "yes" && -x /usr/bin/md5sum ]] && USE_MD5="true" + if [[ "$USE_MD5" == "true" && -x "$MAKEDEV" ]]; then for i in /etc/udev/makedev.d/*.nodes; do if [ -f "$i" ]; then # use a little caching to speedup things diff --git a/udev.spec b/udev.spec index edce2f8..9a62302 100644 --- a/udev.spec +++ b/udev.spec @@ -4,8 +4,8 @@ Summary: A userspace implementation of devfs Name: udev -Version: 151 -Release: 3%{?dist} +Version: 153 +Release: 5%{?dist} License: GPLv2 Group: System Environment/Base Provides: udev-persistent = %{version}-%{release} @@ -13,14 +13,33 @@ Obsoletes: udev-persistent < 0:030-5 Obsoletes: udev-extras < 20090618 Provides: udev-extras = 20090618-1 Source: ftp://ftp.kernel.org/pub/linux/utils/kernel/hotplug/%{name}-%{version}.tar.bz2 -Patch1: udev-151-rules.patch -Patch2: udev-86a7a2f-fix-missing-firmware.patch + +Patch17: 0017-udev-acl-properly-handle-CK-change-events-for-root-u.patch +Patch18: 0018-udev-acl-really-fix-ACL-assignment-in-CK-events.patch +Patch34: 0034-add-LGPL-COPYING-to-libudev-and-GUdev.patch +Patch110: 0110-cdrom_id-only-mark-sr-0-9-as-ID_CDROM.patch +Patch101: udev-151-rules.patch +Patch102: udev-153-n210.patch +Patch103: udev-151-gperf.patch +Patch104: udev-git484e1b2d11b9b89418589d885a625e647881933b.patch +Patch105: udev-153-changer.patch +Patch106: udev-153-trigger.patch +Patch200: 0001-set-SELinux-context-on-add-but-not-on-change-events.patch +Patch300: udev-153-keymap-backport.patch +Patch301: udev-153-cdrom_id-backport.patch Source1: start_udev Source3: udev-post.init Source4: fw_unit_symlinks.sh Source5: udev.sysconfig +Source12: 40-isdn.rules +Source13: 64-md-raid.rules +Source14: 64-device-mapper.rules +Source15: 40-ia64.rules +Source16: 40-s390.rules +Source17: 40-ppc.rules + ExclusiveOS: Linux URL: http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -110,17 +129,34 @@ glib-based applications using libudev functionality. %prep %setup -q -%patch1 -p1 -%patch2 -p1 + +%patch17 -p1 -b .git17 +%patch18 -p1 -b .git18 +%patch34 -p1 -b .git34 + +%patch110 -p1 -b .git110 + +%patch101 -p1 +%patch102 -p1 +%patch103 -p1 +%patch104 -p1 +%patch105 -p1 +%patch106 -p1 + +%patch200 -p1 +%patch300 -p1 +%patch301 -p1 %build +autoreconf -i +automake # get rid of rpath libtoolize -f -c %configure --with-selinux --prefix=%{_prefix} --exec-prefix="" \ - --sysconfdir=%{_sysconfdir} --with-libdir-name=%{_lib} \ - --sbindir="/sbin" --libexecdir=%{udev_scriptdir} \ - --with-rootlibdir=/%{_lib} --enable-introspection \ - --disable-rpath --enable-debug + --sysconfdir=%{_sysconfdir} --with-libdir-name=%{_lib} \ + --sbindir="/sbin" --libexecdir=%{udev_scriptdir} \ + --with-rootlibdir=/%{_lib} --enable-introspection \ + --disable-rpath --enable-debug make %{?_smp_mflags} @@ -143,32 +179,24 @@ touch $RPM_BUILD_ROOT%{_sysconfdir}/scsi_id.config # force relative symlinks ln -sf ..%{udev_scriptdir}/scsi_id $RPM_BUILD_ROOT/sbin/scsi_id -ln -sf ../../sbin/udevadm $RPM_BUILD_ROOT%{_bindir}/udevinfo -ln -sf ../../sbin/udevadm $RPM_BUILD_ROOT%{_bindir}/udevtest -ln -sf ../../sbin/udevadm $RPM_BUILD_ROOT%{_sbindir}/udevmonitor - -ln -sf ../../sbin/udevadm $RPM_BUILD_ROOT/sbin/udevtrigger -ln -sf ../../sbin/udevadm $RPM_BUILD_ROOT/sbin/udevsettle -ln -sf ../../sbin/udevadm $RPM_BUILD_ROOT/sbin/udevcontrol - for i in \ - rules/redhat/40-redhat.rules \ + rules/redhat/40-redhat.rules \ %ifarch ia64 - rules/packages/40-ia64.rules \ + %{SOURCE15} \ %endif %ifarch ppc ppc64 - rules/packages/40-ppc.rules \ + %{SOURCE17} \ %endif %ifarch s390 s390x - rules/packages/40-s390.rules \ + %{SOURCE16} \ %endif - rules/packages/40-isdn.rules \ - rules/packages/64-md-raid.rules \ - rules/packages/64-device-mapper.rules \ - ; do - install -m 0644 "$i" "$RPM_BUILD_ROOT%{udev_scriptdir}/rules.d/${i##*/}" + %{SOURCE12} \ + %{SOURCE13} \ + %{SOURCE14} \ + ; do + install -m 0644 "$i" "$RPM_BUILD_ROOT%{udev_scriptdir}/rules.d/${i##*/}" done - + mkdir -p $RPM_BUILD_ROOT%{udev_scriptdir}/{,devices} install -m 0755 %{SOURCE4} $RPM_BUILD_ROOT%{udev_scriptdir}/fw_unit_symlinks.sh @@ -188,16 +216,16 @@ mkdir -p $RPM_BUILD_ROOT/var/lib/udev/makedev.d %preun if [ "$1" -eq 0 -a -f %{_initrddir}/udev ]; then - if [ -x /sbin/pidof ]; then - pid=$(/sbin/pidof -c udevd) - if [ -n "$pid" ]; then - kill $pid - fi - fi - /sbin/chkconfig --del udev + if [ -x /sbin/pidof ]; then + pid=$(/sbin/pidof -c udevd) + if [ -n "$pid" ]; then + kill $pid + fi + fi + /sbin/chkconfig --del udev fi if [ "$1" -eq 0 ]; then - /sbin/chkconfig --del udev-post + /sbin/chkconfig --del udev-post fi exit 0 @@ -212,29 +240,33 @@ getent group dialout >/dev/null || /usr/sbin/groupadd -g 18 dialout || : # kill daemon if we are not in a chroot if test -f /proc/1/exe -a -d /proc/1/root; then - if test -x /usr/bin/stat -a "$(/usr/bin/stat -Lc '%%D-%%i' /)" = "$(/usr/bin/stat -Lc '%%D-%%i' /proc/1/root)"; then - if test -x /sbin/udevd -a -x /sbin/pidof ; then - /sbin/udevadm control --stop-exec-queue - pid=$(/sbin/pidof -c udevd) - while [ -n "$pid" ]; do - for p in $pid; do - kill $hard $p; - done - pid=$(/sbin/pidof -c udevd) - hard="-9" - done - fi - fi + if test -x /usr/bin/stat -a "$(/usr/bin/stat -Lc '%%D-%%i' /)" = "$(/usr/bin/stat -Lc '%%D-%%i' /proc/1/root)"; then + if test -x /sbin/udevd -a -x /sbin/pidof ; then + /sbin/udevadm control --stop-exec-queue + pid=$(/sbin/pidof -c udevd) + while [ -n "$pid" ]; do + for p in $pid; do + kill $hard $p; + done + pid=$(/sbin/pidof -c udevd) + hard="-9" + done + fi + fi fi exit 0 +%triggerpostun -- udev < 153-5 +[ -c /dev/systty ] && ln -fs tty0 /dev/systty +: + %post # start daemon if we are not in a chroot if test -f /proc/1/exe -a -d /proc/1/root; then - if test "$(/usr/bin/stat -Lc '%%D-%%i' /)" = "$(/usr/bin/stat -Lc '%%D-%%i' /proc/1/root)"; then - /sbin/udevd -d - /sbin/udevadm control --start-exec-queue - fi + if test "$(/usr/bin/stat -Lc '%%D-%%i' /)" = "$(/usr/bin/stat -Lc '%%D-%%i' /proc/1/root)"; then + /sbin/udevd -d + /sbin/udevadm control --start-exec-queue + fi fi /sbin/chkconfig --add udev-post @@ -259,9 +291,6 @@ rm -rf $RPM_BUILD_ROOT %defattr(0644, root, root, 0755) %doc NEWS COPYING README TODO ChangeLog extras/keymap/README.keymap.txt %attr(0755,root,root) /sbin/udevadm -%attr(0755,root,root) /sbin/udevsettle -%attr(0755,root,root) /sbin/udevtrigger -%attr(0755,root,root) /sbin/udevcontrol %attr(0755,root,root) /sbin/udevd %attr(0755,root,root) /sbin/start_udev %attr(0755,root,root) /sbin/scsi_id @@ -286,9 +315,6 @@ rm -rf $RPM_BUILD_ROOT %attr(0755,root,root) %dir %{udev_scriptdir}/rules.d/ %attr(0755,root,root) %{_sysconfdir}/rc.d/init.d/udev-post -%attr(0755,root,root) %{_bindir}/udevtest -%attr(0755,root,root) %{_bindir}/udevinfo -%attr(0755,root,root) %{_sbindir}/udevmonitor %attr(0755,root,root) %dir %{_sysconfdir}/udev/ %attr(0755,root,root) %dir %{_sysconfdir}/udev/rules.d/ %attr(0755,root,root) %dir %{udev_scriptdir}/ @@ -315,26 +341,26 @@ rm -rf $RPM_BUILD_ROOT %ghost %dir %{_sysconfdir}/udev/devices/ %ghost %dir %{_sysconfdir}/dev.d/ -%attr(0755,root,root) %{udev_scriptdir}/modem-modeswitch +%attr(0755,root,root) %{udev_scriptdir}/mobile-action-modeswitch %attr(0755,root,root) %{udev_scriptdir}/pci-db %attr(0755,root,root) %{udev_scriptdir}/usb-db %attr(0755,root,root) %{udev_scriptdir}/keymap %attr(0755,root,root) %{udev_scriptdir}/udev-acl %attr(0755,root,root) %{udev_scriptdir}/v4l_id %attr(0755,root,root) %{udev_scriptdir}/findkeyboards -%dir %attr(0755,root,root) %{udev_scriptdir}/keymaps -%attr(0644,root,root) %{udev_scriptdir}/keymaps/* +%dir %{udev_scriptdir}/keymaps +%{udev_scriptdir}/keymaps/* %attr(0644,root,root) %{_prefix}/lib/ConsoleKit/run-seat.d/udev-acl.ck %files -n libudev %defattr(0644, root, root, 0755) -%doc COPYING +%doc libudev/COPYING %attr(0755,root,root) /%{_lib}/libudev.so.* %files -n libudev-devel %defattr(0644, root, root, 0755) -%doc COPYING libudev/docs/html/* +%doc libudev/COPYING libudev/docs/html/* %{_includedir}/libudev.h %{_libdir}/libudev.so %{_libdir}/pkgconfig/libudev.pc @@ -343,14 +369,16 @@ rm -rf $RPM_BUILD_ROOT %files -n libgudev1 %defattr(0644, root, root, 0755) -%doc COPYING +%doc extras/gudev/COPYING %attr(0755,root,root) %{_libdir}/libgudev-1.0.so.* %attr(0644,root,root) %{_libdir}/girepository-1.0/GUdev-1.0.typelib %files -n libgudev1-devel %defattr(0644, root, root, 0755) -%doc COPYING extras/gudev/docs/html/* +%doc extras/gudev/COPYING extras/gudev/docs/html/* %attr(0755,root,root) %{_libdir}/libgudev-1.0.so +%dir %attr(0755,root,root) %{_includedir}/gudev-1.0 +%dir %attr(0755,root,root) %{_includedir}/gudev-1.0/gudev %attr(0644,root,root) %{_includedir}/gudev-1.0/gudev/*.h %attr(0644,root,root) %{_datadir}/gir-1.0/GUdev-1.0.gir %dir %{_datadir}/gtk-doc/html/gudev @@ -358,6 +386,69 @@ rm -rf $RPM_BUILD_ROOT %attr(0644,root,root) %{_libdir}/pkgconfig/gudev-1.0* %changelog +* Thu Nov 18 2010 Harald Hoyer 153-5 +- fix /dev/systty +Resolves: rhbz#654935 + +* Wed Sep 22 2010 Harald Hoyer 153-4 +- fixed SELinux contexts on "add" events +- backported keymaps +- backported cdrom_id + +* Fri Aug 13 2010 Harald Hoyer 153-3 +- revert the default trigger to "add" + +* Wed Aug 04 2010 Harald Hoyer 153-2 +- trigger with action==add +- add rd_NO_MDIMSM on noiswmd kernel cmdline option +Resolves: rhbz#589774 +- fix console switching and ACLs +Resolves: rhbz#608712 +- fix key mapping for Samsung N210 +Resolves: rhbz#606302 +- fix for blank or audio CDs +Resolves: rhbz#606285 +- fix for scsi changer +Resolves: rhbz#600983 + +* Mon Aug 02 2010 Harald Hoyer 153-1 +- version 153, because device-mapper needs IMPORT{db} +- do not remove udev database +Resolves: rhbz#610925 + +* Thu Jun 10 2010 Bastien Nocera 151-10 +- Revert patch for hid2hci rules, fixes keyboards not going + into HCI (Bluetooth) mode after being plugged in (#595178) + +* Tue Apr 27 2010 Harald Hoyer 151-9 +- more cdrom_id bugfixes to prevent autoclosing + +* Tue Apr 13 2010 Harald Hoyer 151-8 +- more cdrom_id bugfixes for buggy cdroms and CD burning + (bug #577659) + +* Mon Mar 22 2010 Harald Hoyer 151-7 +- only correct the timestamp, if UTC=="no" + +* Mon Mar 22 2010 Harald Hoyer 151-6 +- touch with "--no-create", will not use open() + and trigger devs/watchdogs (bug #575417) + +* Mon Mar 22 2010 Harald Hoyer 151-5 +- fixed return code of touching the device nodes [FAIL] -> [OK] + +* Fri Mar 19 2010 Harald Hoyer 151-4 +- add patch for virtio-ports (#569700) +- own libgudev dirs (#561319) +- minor udev startup script improvements (#549518) +- create /dev/hugepages subdir in start_udev (#541998) +- remove GPL COPYING file from LGPL subpackages (#536843) +- removed symlinks to udevadm +- touch all device nodes after udev settled for the timezone + timestamp (#569335) +- add some upstream bugfixes +- add "-D" to gperf call + * Sun Feb 07 2010 Kyle McMartin 151-3 - udev-86a7a2f-fix-missing-firmware.patch: fix hang when loading microcode (since microcode_intel tries to probe firmware which does @@ -445,7 +536,7 @@ rm -rf $RPM_BUILD_ROOT - git fix: rule-generator: cd - skip by-path links if we create by-id links - git fix: fix possible endless loop for GOTO to non-existent LABEL - git fix: cdrom_id: suppress ID_CDROM_MEDIA_STATE=blank for plain non-writable - CDROM media + CDROM media * Thu Jun 08 2009 Harald Hoyer 142-3 - delay device-mapper changes