commit a267c0a887064720dfab5775a4f09b20b4f8ec37 Merge: d756d10... 97989ad... Author: Linus Torvalds Date: Wed Jul 18 11:25:58 2007 -0700 Merge branch 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb * 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (126 commits) V4L/DVB (5847): Clean up schedule_timeout calls in cpia2 and ivtv code V4L/DVB (5846): Clean up setting state and scheduling timeouts V4L/DVB (5844): ivtv: add high volume debugging flag V4L/DVB (5843): ivtv: fix missing signal_pending check. V4L/DVB (5842): ivtv: Add locking to ensure stream setup is atomic. V4L/DVB (5841): tveeprom: add support for Philips FQ1216LME MK3 tuner. V4L/DVB (5840): fix dst and cx24123: tune() callback changed signess for delay V4L/DVB (5838): dvb-core: Fix signedness warnings (gcc 4.1.1, kernel 2.6.22) V4L/DVB (5837): stv0299: Fix signedness warning (gcc 4.1.1, kernel 2.6.22) V4L/DVB (5836): dvb-ttpci: re-initialize aspect ratio and pan scan after arm crash V4L/DVB (5835): saa7146/dvb-ttpci: Fix signedness warnings (gcc 4.1.1, kernel 2.6.22) V4L/DVB (5834): dvb-core: fix signedness warnings and const stripping V4L/DVB (5832): ir-common: optimize bit extract function V4L/DVB (5831): stradis: use ARRAY_SIZE V4L/DVB (5829): Firmware extract and loading for opera dvb-usb update V4L/DVB (5828): Kconfig: Added GemTek USB radio and removed experimental dependency. V4L/DVB (5826): Usbvision: video mux cleanup V4L/DVB (5825): Alter the tuner type for the WinTV USB UK PAL model. V4L/DVB (5824): Usbvision: Hauppauge WinTV USB SECAM_L fix V4L/DVB (5821): Saa7134: add remote control support for LifeView FlyDVB-S LR300 ... commit d756d10e246a01515d07f8161181b8a14afba7cc Merge: cdf4a64... e9f410b... Author: Linus Torvalds Date: Wed Jul 18 10:32:00 2007 -0700 Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: ext4: extent macros cleanup Fix compilation with EXT_DEBUG, also fix leXX_to_cpu conversions. ext4: remove extra IS_RDONLY() check ext4: Use is_power_of_2() Use zero_user_page() in ext4 where possible ext4: Remove 65000 subdirectory limit ext4: Expand extra_inodes space per the s_{want,min}_extra_isize fields ext4: Add nanosecond timestamps jbd2: Move jbd2-debug file to debugfs jbd2: Fix CONFIG_JBD_DEBUG ifdef to be CONFIG_JBD2_DEBUG ext4: Set the journal JBD2_FEATURE_INCOMPAT_64BIT on large devices ext4: Make extents code sanely handle on-disk corruption ext4: copy i_flags to inode flags on write ext4: Enable extents by default Change on-disk format to support 2^15 uninitialized extents write support for preallocated blocks fallocate support in ext4 sys_fallocate() implementation on i386, x86_64 and powerpc commit cdf4a6482dd4c739f8c1132c5a9356912911fec5 Merge: 485cf92... add0b43... Author: Linus Torvalds Date: Wed Jul 18 10:27:24 2007 -0700 Merge branch 'upstream' of git://git.infradead.org/~dedekind/ubi-2.6 * 'upstream' of git://git.infradead.org/~dedekind/ubi-2.6: (28 commits) UBI: fix compile warning UBI: fix error handling in erase worker UBI: fix comments UBI: remove unneeded error checks UBI: cleanup usage of try_module_get UBI: fix overflow bug UBI: bugfix in max_sqnum calculation UBI: bugfix in sqnum calculation UBI: fix signed-unsigned multiplication UBI: fix bug in atomic_leb_change() UBI: fix message UBI: fix debugging stuff UBI: bugfix in error path UBI: use is_power_of_2() UBI: fix freeing ubi->vtbl while unloading UBI: fix MAINTAINERS UBI: bugfix in ubi_leb_change() UBI: kill homegrown endian macros UBI: cleanup ioctl handling UBI: error path bugfix ... commit 97989ada7628da262eafb4bebce0a319c7cb0f5f Author: Robert P. J. Day Date: Mon Jul 16 10:47:51 2007 -0300 V4L/DVB (5847): Clean up schedule_timeout calls in cpia2 and ivtv code Signed-off-by: Robert P. J. Day Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit f3a43d3082cd9c2308612e0331ad3b1b9d3a7a33 Author: Robert P. J. Day Date: Mon Jul 16 10:46:42 2007 -0300 V4L/DVB (5846): Clean up setting state and scheduling timeouts Replace assignments to "current->state" with the preferred calls to schedule_timeout_interruptible(). Signed-off-by: Robert P. J. Day Signed-off-by: Mauro Carvalho Chehab commit bd58df6d522d5a9c791f6a4820e480e9be60650d Author: Hans Verkuil Date: Tue Jul 10 17:47:07 2007 -0300 V4L/DVB (5844): ivtv: add high volume debugging flag Add support for high volume debug messages, allowing them to be turned on selectively. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 90851fe9fad68db24da8cb497bad7327b97ed3d2 Author: Hans Verkuil Date: Tue Jul 10 15:08:33 2007 -0300 V4L/DVB (5843): ivtv: fix missing signal_pending check. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit f885969196da6ae905162c0d1c5f0553de12cb40 Author: Hans Verkuil Date: Tue Jul 10 14:58:33 2007 -0300 V4L/DVB (5842): ivtv: Add locking to ensure stream setup is atomic. Starting an MPEG and VBI capture simultaneously caused errors in the VBI setup: this setup was done twice when it should be done only for the first stream that is opened. Added a mutex to prevent this from happening. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 0901973f4bde9c1004795c9c2321bdc51f3996f1 Author: Hans Verkuil Date: Tue Jul 10 14:51:33 2007 -0300 V4L/DVB (5841): tveeprom: add support for Philips FQ1216LME MK3 tuner. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 3ea96615381157fc7b94549db559adabd7d4233f Author: Mauro Carvalho Chehab Date: Mon Jul 16 09:27:20 2007 -0300 V4L/DVB (5840): fix dst and cx24123: tune() callback changed signess for delay tune() dvb_frontend callback changed delay signess: int (*tune)(struct dvb_frontend* fe, struct dvb_frontend_parameters* params, unsigned int mode_flags, - int *delay, + unsigned int *delay, This change caused warnings on cx24123 and dst modules: /home/v4l/master/v4l/cx24123.c:1034: warning: initialization from incompatible pointer type /home/v4l/master/v4l/dst.c:1782: warning: initialization from incompatible pointer type /home/v4l/master/v4l/dst.c:1808: warning: initialization from incompatible pointer type /home/v4l/master/v4l/dst.c:1837: warning: initialization from incompatible pointer type /home/v4l/master/v4l/dst.c:1860: warning: initialization from incompatible pointer type This patch corrects the function prototype on both modules to follow the core change. Signed-off-by: Mauro Carvalho Chehab commit 260f8d7c4cda79b087a182eb03e8574ba41a171e Author: Oliver Endriss Date: Fri Jul 13 11:54:35 2007 -0300 V4L/DVB (5838): dvb-core: Fix signedness warnings (gcc 4.1.1, kernel 2.6.22) Fix signedness warnings (gcc 4.1.1, kernel 2.6.22). Signed-off-by: Oliver Endriss Signed-off-by: Mauro Carvalho Chehab commit 0402a6c2aadbd5ff0e70a67f80a4907bf76792c6 Author: Oliver Endriss Date: Thu Jul 12 23:22:59 2007 -0300 V4L/DVB (5837): stv0299: Fix signedness warning (gcc 4.1.1, kernel 2.6.22) Fix signedness warning (gcc 4.1.1, kernel 2.6.22). Signed-off-by: Oliver Endriss Signed-off-by: Mauro Carvalho Chehab commit defd574ec07edaa1587da144d03b18495ab484b1 Author: Oliver Endriss Date: Thu Jul 12 23:08:07 2007 -0300 V4L/DVB (5836): dvb-ttpci: re-initialize aspect ratio and pan scan after arm crash Re-initialize aspect ratio and pan scan after arm crash. Signed-off-by: Oliver Endriss Signed-off-by: Mauro Carvalho Chehab commit 804b4458943f14bf144d3c3ba50097ced9b27b29 Author: Oliver Endriss Date: Thu Jul 12 20:37:50 2007 -0300 V4L/DVB (5835): saa7146/dvb-ttpci: Fix signedness warnings (gcc 4.1.1, kernel 2.6.22) Fix signedness warnings (gcc 4.1.1, kernel 2.6.22). Signed-off-by: Oliver Endriss Signed-off-by: Mauro Carvalho Chehab commit 372280d2a3593e90d8849a5dc5676d2e9799e3a3 Author: Trent Piepho Date: Fri Jul 13 18:46:19 2007 -0300 V4L/DVB (5834): dvb-core: fix signedness warnings and const stripping Make some pointers const, and then delete some now unnecessary casts, which were the wrong signedness anyway, being used to strip the const from another pointer. Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit d67be61ebe5efaf9c4c11bf168781d678854c966 Author: Trent Piepho Date: Wed Jul 11 20:28:44 2007 -0300 V4L/DVB (5832): ir-common: optimize bit extract function New code is simpler, shorter, compiles to about half the size, and is 2 to 4 times faster depending on how many bits in the mask are set. Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit ba2cf98249795f03792d1409a3b6aaa589ea0745 Author: Trent Piepho Date: Thu Jul 5 19:04:27 2007 -0300 V4L/DVB (5831): stradis: use ARRAY_SIZE sizeof(palette2fmt) / sizeof(u32) => ARRAY_SIZE(palette2fmt) Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 59800555f79a52394c3c29e19e448b4635daf14c Author: Marco Gittler Date: Wed Jul 4 19:18:34 2007 -0300 V4L/DVB (5829): Firmware extract and loading for opera dvb-usb update Better way of creating and loading the firmware used. Update for get_dvb_firmware script to extract the files for opera usb-box Help file for creating the firmware added Signed-off-by: Marco Gittler Signed-off-by: Mauro Carvalho Chehab commit b31c33bd8b339e426138dd267ec969291f802a0d Author: Douglas Schilling Landgraf Date: Mon Jul 2 23:16:17 2007 -0300 V4L/DVB (5828): Kconfig: Added GemTek USB radio and removed experimental dependency. Added GemTek USB radio and removed experimental dependency. Signed-off-by: Douglas Schilling Landgraf Signed-off-by: Mauro Carvalho Chehab commit 66a17879e9f18a38c4ca5e6ba600a3f5b1b51188 Author: Thierry MERLE Date: Tue Jun 26 16:35:30 2007 -0300 V4L/DVB (5826): Usbvision: video mux cleanup - usbvision_muxsel simplified, now uses some well known constants. - since the decoder needs to change input norm, call to muxsel added when changing video standard. Signed-off-by: Thierry MERLE Acked-by: Dwaine Garden Signed-off-by: Mauro Carvalho Chehab commit ffddcaa6ec4e85ed8504deac1f51f44c86ec1d23 Author: Matthew Garrett Date: Sat Jun 30 15:41:27 2007 -0300 V4L/DVB (5825): Alter the tuner type for the WinTV USB UK PAL model. Alter the tuner type for the WinTV USB UK PAL model. Signed-off-by: Matthew Garrett Signed-off-by: Thierry MERLE Signed-off-by: Mauro Carvalho Chehab commit 485cf925d8b7a6b3c62fe5f1e167f2d0d4edf32a Merge: 31bdc5d... 3fd8f9e... Author: Linus Torvalds Date: Wed Jul 18 10:24:36 2007 -0700 Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 * 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (24 commits) [NETFILTER]: xt_connlimit needs to depend on nf_conntrack [NETFILTER]: ipt_iprange.h must #include [IrDA]: Fix IrDA build failure [ATM]: nicstar needs virt_to_bus [NET]: move __dev_addr_discard adjacent to dev_addr_discard for readability [NET]: merge dev_unicast_discard and dev_mc_discard into one [NET]: move dev_mc_discard from dev_mcast.c to dev.c [NETLINK]: negative groups in netlink_setsockopt [PPPOL2TP]: Reset meta-data in xmit function [PPPOL2TP]: Fix use-after-free [PKT_SCHED]: Some typo fixes in net/sched/Kconfig [XFRM]: Fix crash introduced by struct dst_entry reordering [TCP]: remove unused argument to cong_avoid op [ATM]: [idt77252] Rename CONFIG_ATM_IDT77252_SEND_IDLE to not resemble a Kconfig variable [ATM]: [drivers] ioremap balanced with iounmap [ATM]: [lanai] sram_test_word() must be __devinit [ATM]: [nicstar] Replace C code with call to ARRAY_SIZE() macro. [ATM]: Eliminate dead config variable CONFIG_BR2684_FAST_TRANS. [ATM]: Replacing kmalloc/memset combination with kzalloc. [NET]: gen_estimator deadlock fix ... commit a1bad7773e562f331b5951def24f73c38579e0cb Author: Thierry MERLE Date: Tue Jun 26 16:35:30 2007 -0300 V4L/DVB (5824): Usbvision: Hauppauge WinTV USB SECAM_L fix - Hauppauge WinTV USB SECAM_L fixed (needed some picture X and Y shiftings) Signed-off-by: Thierry MERLE Signed-off-by: Mauro Carvalho Chehab commit f5c965abdf44ee6983712e54bbbcc7905af56d39 Author: James Le Cuirot Date: Mon Jul 2 12:53:25 2007 -0300 V4L/DVB (5821): Saa7134: add remote control support for LifeView FlyDVB-S LR300 It has been confirmed that the FlyDVB IR codes currently in the kernel work with the LifeView FlyDVB-S LR300. This one line addition adds it to the list of supported cards. Signed-off-by: James Le Cuirot Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 9b7cc42917ed07ab75269d35cd7709a5fd6336e0 Author: Mauro Carvalho Chehab Date: Mon Jul 2 15:48:40 2007 -0300 V4L/DVB (5820): Cleanup on cinergyT2: Remove unneeded if(1) Before kernel 2.6.14, the driver checked for status before stopping the thread. So, a compatibility test did exist. After 2.6.14, the if (state) were replaced by: if (1) However, it makes no sense to keep the if(1). Signed-off-by: Mauro Carvalho Chehab commit 18f3fa1e2eab297a2f7ec704385fa0ecfda0de55 Author: Mauro Carvalho Chehab Date: Mon Jul 2 15:39:57 2007 -0300 V4L/DVB (5819): Cleanup: reorder some includes Some includes were added after some non-include macros, on old drivers. Better to keep all includes at the beginning of the files. This change also helps to make backports to properly work at the development tree. Signed-off-by: Mauro Carvalho Chehab commit 7e520d09f1a4b3da1d09a4540e3f4fa852658a0d Author: Jean Delvare Date: Sun Jul 1 18:37:51 2007 -0300 V4L/DVB (5815): Cx88: i2c structure templates clean-up Clean up the use of structure templates in cx88-i2c and cx88-vp3054-i2c. For one thing, a real template is supposed to be read-only. And in some cases it's more efficient to initialize the few fields we need individually. This clean-up shrinks cx88-i2c.o by 33% and cx88-vp3054-i2c.o by 49% (x86_64). Signed-off-by: Jean Delvare Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 4de7bb44cc6aa6e0a74f80c628f600da5b8fcd47 Author: Adrian Bunk Date: Sun Jul 1 18:24:33 2007 -0300 V4L/DVB (5814): Unexport dvb_pll_configure Now that it's static, it should no longer be exported to modules... Signed-off-by: Adrian Bunk Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 8fb2191a74a0e2a29002c06084e015d33d2ecdda Author: Adrian Bunk Date: Sun Jul 1 18:22:00 2007 -0300 V4L/DVB (5813): TUNER_TEA5761 kconfig fixes The following doesn't make much sense: drivers/media/video/Kconfig: ... config TUNER_TEA5761 tristate "TEA 5761 radio tuner (EXPERIMENTAL)" ... drivers/media/video/Makefile: ... ifneq ($(CONFIG_TUNER_TEA5761),) tuner-objs += tea5761.o endif ... With this setup, TUNER_TEA5761=m is equivalent to TUNER_TEA5761=y. This patch therefore changes TUNER_TEA5761 to a bool. The missing dependency on EXPERIMENTAL the prompt text indicates also gets added by this patch. Additionally, the Makefile entry can now be written in a more compact way. Signed-off-by: Adrian Bunk Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 51b540292a349b380ccc0572401c6ac343acdf4a Author: Matthias Kaehlcke Date: Mon Jul 2 10:19:38 2007 -0300 V4L/DVB (5811): Use mutex instead of semaphore in Virtual Video driver The Virtual Video driver uses a semaphore as mutex. Use the mutex API instead of the (binary) semaphore. Signed-off-by: Matthias Kaehlcke Signed-off-by: Mauro Carvalho Chehab commit b9378fdbc334d1575b492108eac822a78c0c46d9 Author: Matthias Kaehlcke Date: Mon Jul 2 10:04:52 2007 -0300 V4L/DVB (5809): Use mutex instead of semaphore in Philips webcam driver The Philips webcam driver uses a semaphore as mutex. Use the mutex API instead of the (binary) semaphore. -- Signed-off-by: Matthias Kaehlcke Signed-off-by: Mauro Carvalho Chehab commit 55c0d1005a0e5f590f71f918e49bdc81362f93a6 Author: Trent Piepho Date: Fri Jun 29 00:17:36 2007 -0300 V4L/DVB (5807): Bttv: Add support for DBG_[SG]_REGISTER ioctls Adds the advanced debugging register read/write ioctl support to the bttv driver. Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 8c2c0dfe4da28a152c0de2c2ca3a66c1bc2fef7c Author: Trent Piepho Date: Thu Jun 28 18:30:36 2007 -0300 V4L/DVB (5806): Bttv: Be consistent in using symbolic names instead of constants For svhs, tuner, and tuner_type, be consistent in using UNSET instead of -1. For tuner_type also consistently use the existing constants: 0 => TUNER_TEMIC_PAL 1 => TUNER_PHILIPS_PAL_I 2 => TUNER_PHILIPS_NTSC 4 => TUNER_ABSENT 5 => TUNER_PHILIPS_PAL 21 => TUNER_TEMIC_4039FR5_NTSC 25 => TUNER_LG_PAL_I_FM Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit ac7dc84584310a836d13236767d71545f5b695b3 Author: Trent Piepho Date: Thu Jun 28 17:51:08 2007 -0300 V4L/DVB (5805): Bttv: Fix problems with probing for non-existent tuners The bttv driver has code to detect if a tda9887 is present, that was previous used to auto-load the tda9887 driver. Now there is no tda9887 driver, so the code is pointless; it just figures out if it should load the driver and then does nothing. For cards that are defined as having no tuner, the init code would still do i2c probes for various tuner devices and auto-load the tuner module. That can be skipped for cards that don't need it. The code is made to understand that in addition to 'UNSET', 'TUNER_ABSENT' also means no tuner. The tuner into printk()s are also made nicer. Levels are added, INFO or WARNING, depending on the meaning. For cards with no tuner, or no tuner defined, a more informative message is printed. Card has no tuner, before patch: bttv0: tuner type=-1 or bttv0: tuner type=4 After patch: bttv0: tuner absent Card has a tuner, but the type isn't defined, before patch: bttv0: tuner type=-1 After patch: bttv0: tuner type unset [<- also warning now, as the tuner won't work right] Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 27cb786f4ec5fe85e9e2deffa4d33eed2f588cb0 Author: Michael Krufky Date: Thu Jun 28 12:19:20 2007 -0300 V4L/DVB (5803): Bttv: add support for DViCO FusionHDTV 2 add analog video support for DViCO FusionHDTV 2 Thanks to Todd Ignasiak for donating the card. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit c350f617ff5440dedea63b9d7826644742ec215d Author: Michael Krufky Date: Wed Jun 27 16:26:32 2007 -0300 V4L/DVB (5801): Tuner: update FCV1236D ranges to match the datasheet Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit b82736362b24046d6d2279260ce0b88653dc43da Author: Michael Krufky Date: Wed Jun 27 14:38:45 2007 -0300 V4L/DVB (5800): Tuner: correct description of Philips FCV1236D tuner The old description was "Philips 1236D ATSC/NTSC dual in", which can be confused with other Philips tuner models. This patch corrects the name to "Philips FCV1236D ATSC/NTSC dual in", and updates the range and params array names to match the description. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit cd2cd0aad0c8d5d29492335307b371f247b7a60f Author: Michael Krufky Date: Sun Jun 24 18:14:52 2007 -0300 V4L/DVB (5799): Or51211: remove hardcoded fcv1236d tuner programming - Remove hardcoded fcv1236d tuner programmming from or51211.c - Alter dvb-bt8xx for the pcHDTV-2000 to use dvb-pll for fcv1236d support. Thanks to Jarom Hatch for testing this change. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit f1b24397e86c4c5b6984e2e67c17a53cdab14b35 Author: Michael Krufky Date: Fri Oct 13 22:18:01 2006 -0300 V4L/DVB (5798): Dvb-pll: add support for Philips fcv1236d This patch adds support to the dvb-pll library for the Philips fcv1236d tuner, based on the FCV1236D datasheet. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit d06cdbe59068a143ff2de2474fea62923cb7026f Author: Marco Gittler Date: Thu Jun 28 10:10:00 2007 -0300 V4L/DVB (5795): Fix: remove unused struct that could avoiding load the firmware The dvb_usb_device* d is not used anymore and can be removed. Signed-off-by: Marco Gittler Signed-off-by: Mauro Carvalho Chehab commit 8218b0b2caecf4af55742e12e9986c15605bb197 Author: Michael Krufky Date: Tue Jun 26 13:12:08 2007 -0300 V4L/DVB (5793): Tuner: remove hardware-specific info from public header Move internal structures and debug macros to drivers/media/video/tuner-driver.h Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit bebeaea0a54869b59b45ea22a93f325ce0369d61 Author: Antoine Jacquet Date: Mon Jun 25 16:00:34 2007 -0300 V4L/DVB (5792): Zr364xx: add support for Trust Powerc@m 970Z Add Trust Powerc@m 970Z (0x06d6:0x003b) to the list of supported devices. Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit ea6337417da26a74a3b91c554ae9823995f8a84d Author: Mauro Carvalho Chehab Date: Mon Jun 25 15:42:01 2007 -0300 V4L/DVB (5791): Fix Kbuild for kbd-ir-i2c Potentially, all board types with I2C and IR support can use an i2c based IR. Currently, the driver is selected only if bt848 or saa7134 boards are selected. Signed-off-by: Mauro Carvalho Chehab commit 2f3ed0538b2ac6d63b95c04b0ee0e7b9ac1ee220 Author: Mauro Carvalho Chehab Date: Mon Jun 25 15:33:41 2007 -0300 V4L/DVB (5790): Fix error handling for stv680 Signed-off-by: Mauro Carvalho Chehab commit 2d9078f73eafb2606e1adbb4e551d0cf1f5daf89 Author: Mauro Carvalho Chehab Date: Mon Jun 25 15:21:05 2007 -0300 V4L/DVB (5789): Fix 3dfx Voodoo entries on Cardlist Signed-off-by: Mauro Carvalho Chehab commit 829ea96477e775df0698b54dbfa913b6b55a4d6d Author: Michael Krufky Date: Mon Jun 25 14:54:09 2007 -0300 V4L/DVB (5788): Cx88-input: convert nested if's to switch..case In the function, cx88_ir_handle_key: - convert nested if statement to a switch..case block Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit e7d11ecbde987e56845cff012b4a28d7001667b8 Author: Edgar Pisani Date: Mon Jun 25 14:46:05 2007 -0300 V4L/DVB (5787): Cx88: add remote control support for Leadtek Winfast DTV1000 Signed-off-by: Edgar Pisani Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 39cf1e810a6b464a8469bf318f21206d84ffb1d8 Author: Jan Frey Date: Mon Jun 25 14:34:06 2007 -0300 V4L/DVB (5786): Ir-kbd-i2c: add support for Hauppauge HVR1300 remote - add support for the I2C based IR transceiver of the Hauppauge HVR-1300 - remove bad code from cx88-input.c Signed-off-by: Jan Frey Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 434b25263a236c9dd980617d69863ba0eff8c744 Author: Wade Berrier Date: Mon Jun 25 13:02:16 2007 -0300 V4L/DVB (5785): Revisited: 3dfx Voodoo TV 200 (US) Fix support for 3dfx Voodoo TV 200 variant Signed-off-by: Wade Berrier Signed-off-by: Mauro Carvalho Chehab commit 096bb77abac4e44c37870f4f8adaec813295eb23 Author: Michael Krufky Date: Fri Jun 22 17:41:07 2007 -0300 V4L/DVB (5784): Dibusb-mb: fix tuner autodetection regression We must set i2c_msg.addr in order for the autodetection test to succeed! Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 7d816b256df83070e75d4f738c10d66bfc192040 Author: Mauro Carvalho Chehab Date: Fri Jun 22 17:26:54 2007 -0300 V4L/DVB (5783): Fix excess of debug messages on cx88-mpeg Closes the issue opened on Kernel bugzilla: http://bugzilla.kernel.org/show_bug.cgi?id=8383 There's no need to print timeout without debug turned on: Apr 27 23:02:14 video kernel: cx88[1]/2-mpeg: cx8802_timeout Signed-off-by: Mauro Carvalho Chehab commit 47a9991e806940f400f90d7b9cbcf7c2925e4fce Author: Michael Krufky Date: Tue Jun 12 16:10:51 2007 -0300 V4L/DVB (5780): Dvb: Remove static dependencies on dvb-pll This patch removes all static dependencies on the dvb-pll module. All exported dvb_pll_desc's have been UNexported, and the caller will reference the individual dvb_pll_desc by it's index in the pll_list array. Signed-off-by: Michael Krufky Signed-off-by: Trent Piepho Signed-off-by: Patrick Boettcher Acked-by: Oliver Endriss Acked-by: Manu Abraham Signed-off-by: Mauro Carvalho Chehab commit 6c08d9290e2fc87b217d0f7c9cd67c9240ad7147 Author: Michael Krufky Date: Tue Jun 12 12:43:25 2007 -0300 V4L/DVB (5779): Dibusb-mb: fix broken 'tuner_pass_ctrl' functionality 'tuner_pass_ctrl' functionality of the dib3000-mb devices was broken in the previous changeset: "dibusb-mb: convert pll handling to properly use dvb-pll" This patch fixes this problem by assigning this functionality to the i2c_gate_ctrl callback Signed-off-by: Michael Krufky Signed-off-by: Patrick Boettcher Signed-off-by: Mauro Carvalho Chehab commit 865dd115c95df6997f3d9dd638e6f92298f0422f Author: Michael Krufky Date: Tue Jun 12 12:40:35 2007 -0300 V4L/DVB (5778): Dvb-usb: kill unused tuner/i2c functions These two functions are no longer being used: dvb_usb_tuner_init_i2c dvb_usb_tuner_set_params_i2c This functionality has been taken over by dvb-pll Signed-off-by: Michael Krufky Signed-off-by: Patrick Boettcher Signed-off-by: Mauro Carvalho Chehab commit 4ce15678926cef4886df46964142fc2520c216cd Author: Trent Piepho Date: Sat Jun 2 16:30:46 2007 -0300 V4L/DVB (5777): Dvb-pll digitv dvb-usb: Eliminate last user of dvb_pll_configure The last user of dvb_pll_configure was the dvb-usb function dvb_usb_tuner_calc_regs(), which was nothing more than a wrapper around dvb_pll_configure(). It's just a copy of the functionality provided by the tuner_ops calc_regs method, and can be deleted. There were two users of dvb_usb_tuner_calc_regs(). One was dvb_usb_tuner_set_params_i2c(), which is converted to use fe->ops.tuner_ops.calc_regs(). The other was the digitv driver. This driver can use one of two demods, mt352 or nxt6000. For the mt352, the driver would set tuner_ops.calc_regs to dvb_usb_tuner_calc_regs(). We can just attach dvb_pll and use the tuner_ops.calc_regs() provided by that module. For the nxt600, the driver would set tuner_ops.set_params to digitv_nxt6000_tuner_set_params. That function would in turn use dvb_usb_tuner_calc_regs(). We convert it to use tuner_ops.calc_regs() instead, and use dvb_pll_attach. The digitv_tuner_attach() needs to know which frontend was attached by digitv_frontend_attach(), since the nxt6000 needs tuner_ops.set_params() to be overridden with digitv_nxt6000_tuner_set_params(). So, to do this a digitv_state that says which frontend was used is added to the dvb_usb_device private state field. Signed-off-by: Trent Piepho Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit b784e526a8333db57d1b9f385a12553066bdba64 Author: Rafael Bilski Date: Wed Jun 20 05:37:27 2007 -0300 V4L/DVB (5776): Hardware MPEG audio fix for SAA7134 based "KNC One TV-Station DVR" card With previous patch card is generating MPEG audio stream too. Unfortunatly I2S audio output is muted. Unmute it. Signed-off-by: Rafal Bilski Signed-off-by: Mauro Carvalho Chehab commit aac0ca6a8b84541b28af9d18d8b84f90653ce0d0 Author: Rafał Bilski Date: Wed Jun 20 05:36:26 2007 -0300 V4L/DVB (5775): Alsa fix for SAA7134 based "KNC One TV-Station DVR" card Sound recording doesn't work for this card because ACNI and ACPF are not set before snd_card_saa7134_capture_prepare(). As a result timeout occurs. These registers aren't poked because thread never gets wake up signal. ACNI initialization is done in the thread. Sound is muted when capture stops. Shouldn't be because it may be used during TV playback. Signed-off-by: Rafal Bilski Signed-off-by: Mauro Carvalho Chehab commit 6d7930e0cde1b27c3beca399e233be058ac0b93f Author: Michael Krufky Date: Fri Jun 15 19:17:46 2007 -0300 V4L/DVB (5772): Cx88: remove two unused pointers from struct cx8802_dev The following two pointers in struct cx8802_dev are unused - remove them: void* fe_handle; int (*fe_release)(void *handle); Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 302170a4b47e869372974abd885dd11d5536b64a Author: Michael Krufky Date: Fri Jun 15 19:14:52 2007 -0300 V4L/DVB (5771): Get_dvb_firmware: update script for new location Get_dvb_firmware: update script for new location of sp8870 firmware This url is no longer valid: http://www.technotrend.de/new/217g/tt_Premium_217g.zip Replace with: http://www.softwarepatch.pl/9999ccd06a4813cb827dbb0005071c71/tt_Premium_217g.zip Thanks-to: Tobias Stoeber Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit f5948bbab04988f2b58e1a7ca893ffcf5dcfa243 Author: Hans Verkuil Date: Sat Jun 16 18:24:47 2007 -0300 V4L/DVB (5770): Ivtv: fix return code of VIDIOC_G/S_FBUF when no FB is present Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 47fd3ba9fc62d23a985f4969719c3091438d21c5 Author: Hans Verkuil Date: Sat Jun 16 17:02:11 2007 -0300 V4L/DVB (5769): Ivtv: fix broken VBI output support The old service_set_out setting was still tested, even though it no longer was ever set and was in fact obsolete. This meant that everything that was written to /dev/vbi16 was ignored. Removed the service_set_out variable altogether and now it works again. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 27b5a3957a205bcaa07952ed27981f69b2b2f764 Author: Hans Verkuil Date: Sat Jun 16 16:46:56 2007 -0300 V4L/DVB (5768): Ivtv: fix converity warning Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 4052fcc7ba32ebd54cc907991cb855d909ce9d1c Author: Luca Risolia Date: Wed Jun 13 15:11:15 2007 -0300 V4L/DVB (5767): ZC0301 driver updates - Make the driver depend on V4L2 only (KConfig) - Better and safe locking mechanism of the device structure on open(), close() and disconnect() - Use kref for handling device deallocation - Generic cleanups Signed-off-by: Luca Risolia Signed-off-by: Mauro Carvalho Chehab commit 3b2ae0be9e246974db65a5bf4ccd2de328f3dede Author: Luca Risolia Date: Wed Jun 13 14:52:01 2007 -0300 V4L/DVB (5766): ET61x251 driver updates - Make the driver depend on V4L2 only (KConfig) - Better and safe locking mechanism of the device structure on open(), close() and disconnect() - Use kref for handling device deallocation - Generic cleanups Signed-off-by: Luca Risolia Signed-off-by: Mauro Carvalho Chehab commit 3770be34199ace8c497ce454cebd7d63347dc4c3 Author: Luca Risolia Date: Wed Jun 13 14:37:50 2007 -0300 V4L/DVB (5765): SN9C1xx driver updates - Add support for pair OV7630+SN9C120 - Better and safe locking mechanism of the device structure on open(), close() and disconnect() - Use kref for handling device deallocation - Generic cleanups Signed-off-by: Luca Risolia Signed-off-by: Mauro Carvalho Chehab commit a6e2b40cb430e1e3a22fbb56807edebf71bf6188 Author: Mauro Carvalho Chehab Date: Fri Jun 8 08:21:27 2007 -0300 V4L/DVB (5763): Fix tea5761 unselection Signed-off-by: Mauro Carvalho Chehab commit 5d807c9fc3fe8a88f1bb95a54da11cebed1612a6 Author: Michael Krufky Date: Wed Jun 6 16:17:57 2007 -0300 V4L/DVB (5759): Tuner-simple: store tuning operations in tuner_operations struct Create static struct tuner_operations simple_tuner_ops for tuner-simple tuning function callback pointers Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 0f838f8d02415a25358850cc32d36cd72c2a798b Author: Michael Krufky Date: Wed Jun 6 16:17:17 2007 -0300 V4L/DVB (5758): Tea5767: store tuning operations in tuner_operations structure Create static struct tuner_operations tea5767_tuner_ops for tea5767 tuning function callback pointers Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit e407cd54eecc955b2658106403a294612bf4ed66 Author: Michael Krufky Date: Wed Jun 6 16:16:29 2007 -0300 V4L/DVB (5757): Tea5761: store tuning operations in tuner_operations structure Create static struct tuner_operations tea5761_tuner_ops for tea5761 tuning function callback pointers Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 9af596ebc7ad3afb0df520b4becad915dd5a5584 Author: Michael Krufky Date: Wed Jun 6 16:15:48 2007 -0300 V4L/DVB (5756): Tda9887: store tuning operations in tuner_operations structure Create static struct tuner_operations tda9887_tuner_ops for tda9887 tuning function callback pointers Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 7fd8b263678ab8430b49c99976ade681f8a78439 Author: Michael Krufky Date: Wed Jun 6 16:15:15 2007 -0300 V4L/DVB (5755): Tda8290: store tuning operations in tuner_operations structure Create static struct tuner_operations tda8290_tuner_ops for tda8290 tuning function callback pointers Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit c22bcb07ad4555fe7ac4ce724c8ad1de889f9477 Author: Michael Krufky Date: Wed Jun 6 16:14:18 2007 -0300 V4L/DVB (5754): Mt20xx: store tuning operations in tuner_operations structure Create static struct tuner_operations mt2050_tuner_ops and mt2032_tuner_ops for mt20xx tuning function callback pointers Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 7a91a80a0d1a0a83a94e773ec6245b31b7c4ceed Author: Michael Krufky Date: Wed Jun 6 16:10:39 2007 -0300 V4L/DVB (5753): Tuner: create struct tuner_operations Move tuner callback function pointers out of struct tuner, into struct tuner_operations. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 018ec5440b4994f560cdde78be6fb10d7ab370d7 Author: Mauro Carvalho Chehab Date: Thu Jun 7 08:26:37 2007 -0300 V4L/DVB (5750): Remove obsoleted support for PROC_FS on vicam.c Procfs support on V4L were converted to sysfs support by a pre-2.6 patch: http://www.ussg.iu.edu/hypermail/linux/kernel/0307.1/2356.html There's no sense on keeping the dead code inside vicam.c. Also,it won't work anyway, as part of proc_fs support were previously inside videodev.c. Signed-off-by: Mauro Carvalho Chehab commit 890be2bb55774290479672b98fcb0486b57e758e Author: Mauro Carvalho Chehab Date: Thu Jun 7 08:10:41 2007 -0300 V4L/DVB (5774a): Remove CONFIG_BIGPHYS_AREA from zoran_driver CONFIG_BIGPHYS_AREA is an out-of-tree kernel patch. It makes no sense to keep supporting this on mainstream. The out-of-tree compilation with CONFIG_BIGPHYS_AREA will still be preserved at the v4l-dvb development tree at: http://linuxtv.org/hg/v4l-dvb Signed-off-by: Mauro Carvalho Chehab commit b7c97abd8171709cc35d8aab70b9962fcad9f9fa Author: Michael Krufky Date: Wed Jun 6 15:28:10 2007 -0300 V4L/DVB (5747): Tea5761: remove duplicated "#include " The line, "#include " appears twice. This patch removes the second occurance. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit f3a0d86f1dc60c3ae13ccde188c533e58e7e3197 Author: Trent Piepho Date: Mon Jun 4 20:18:51 2007 -0300 V4L/DVB (5745): Dvb: use '+=' instead of '=' for EXTRA_CFLAGS The Makefiles in the dvb directory tree used '=' when defining EXTRA_CFLAGS rather than '+=', which is far more common in the rest of the kernel source. = 14 times (9 of which this patch removes) := 25 times += 123 times This change also has certain advantages for the out of kernel v4l-dvb build system. Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 052c50d91642f10e10c3c10837c89a7355881e76 Author: Michael Krufky Date: Mon Jun 4 16:00:45 2007 -0300 V4L/DVB (5743): Tuner: clean up kfree() after release Although it is safe to kfree(NULL), We only need to kfree(priv) if the release callback is undefined. As it stands now, there is some redundancy in the operation of releasing the priv data structures. This patch will call kfree(priv) and set priv to NULL, if the release callback isnt defined. Otherwise, let the release callback handle this itself. Thanks to Mauro Carvalho Chehab for suggesting this. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 024cf53089f7c8e58934407f07ca2a7b5bed3b06 Author: Michael Krufky Date: Mon Jun 4 15:20:11 2007 -0300 V4L/DVB (5742): Tuner: define release callback for mt20xx, tda9887 and tda8290 Define tuner release callbacks for mt20xx, tda9887 and tda8290, so that these drivers can release their own private structures themselves. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit be2b85a13543bbaf1a141b3a54f84c1e3b059e69 Author: Michael Krufky Date: Mon Jun 4 14:40:27 2007 -0300 V4L/DVB (5741): Tuner: add release callback Individual tuner drivers are now allocating memory themselves for their own private data structures. This changeset adds a release callback to the tuner operations, so that newer drivers that may require more complex data structures may release this private data themselves. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 9ee476a56c3ee119a02b6823659f5698b1241f04 Author: Adrian Bunk Date: Tue Jun 5 05:22:00 2007 -0300 V4L/DVB (5740): Git-dvb: fix the tea5761 tuner support Due to a typo the tea5761 tuner support was dead code. This patch also fixes a bug in the no longer dead code: A void function can't return anything. Signed-off-by: Adrian Bunk Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit 0c71bf1c3065e80cc3ab91293829169bdeda2c42 Author: Robert P. J. Day Date: Tue Jun 5 05:20:56 2007 -0300 V4L/DVB (5739): Replace C code with calls to ARRAY_SIZE macro. Signed-off-by: Robert P. J. Day Signed-off-by: Mauro Carvalho Chehab commit e0099e9edabd855bf83d3f57b1843f0b06bfb19d Author: Michael Krufky Date: Wed May 30 13:29:32 2007 -0300 V4L/DVB (5734): Cx88: kill dev->fw_size Now that cx88-blackbird is only accepting the official firmware image, we no longer have any need to store the size of the firmware inside the cx88 data structure. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 25472237320b4979d38eb15bc842f592c94d20f5 Author: Hans Verkuil Date: Wed May 30 09:39:46 2007 -0300 V4L/DVB (5733): Blackbird should accept only new cx2341x encoding firmwares Remove temporary support for older 256 kB firmwares. ivtv, pvrusb2 and blackbird can now all handle the newer larger firmwares, so support for the older (buggier) firmware can be removed. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit a957641bbafc9f44050c965fe1ddc0f7b771d416 Author: Hans Verkuil Date: Tue May 29 07:18:55 2007 -0300 V4L/DVB (5729): Remove support for 256 Kb firmware files. For backwards compatibility firmware files of 256 Kb were allowed: all drivers have now been updated to support the newer larger firmwares so remove this compatibility code and only support the newer firmware. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 74fa39e5902faf1f5eb3ee642e2e069875a0343e Author: Mauro Carvalho Chehab Date: Tue May 29 07:14:59 2007 -0300 V4L/DVB (5727): Remove VIVI_SCATTER vivi scatter method were used as a proof of concept. It can be safelly removed from mainstream, since the current method is faster and better than the previous solution. Signed-off-by: Mauro Carvalho Chehab commit 3e0e38e6e4b6f64f22f2fb6aca36b25f10f779cb Author: Christoph Hellwig Date: Fri Jun 1 20:15:26 2007 -0300 V4L/DVB (5724): Saa7134-tvaudio: kthread conversion Acked-by: Hermann Pitton Signed-off-by: Christoph Hellwig Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit b208319993ceff7ebfcc6bb914fe94d29e48a891 Author: Michael Krufky Date: Tue May 29 22:54:06 2007 -0300 V4L/DVB (5719): Tuner: Move device-specific private data out of tuner struct Create private data struct for device specific private data. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 56584c9ea9a6dcd672f97ebfeebc4903e8b903bc Author: Michael Krufky Date: Tue May 29 15:36:37 2007 -0300 V4L/DVB (5718): Mt20xx: whitespace cleanup replace leading spaces with tabs Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 2e02b9a717388c99f2c2ef0aa03f86334bbf8fc7 Author: Douglas Schilling Landgraf Date: Sun May 27 14:05:01 2007 -0300 V4L/DVB (5705): Removed unnecessary .hardware from video_device struct. From: Douglas Schilling Landgraf Signed-off-by: Douglas Schilling Landgraf Signed-off-by: Mauro Carvalho Chehab commit 805b35634b6c349738664619a6d2eb8ece02fe63 Author: Robert P. J. Day Date: Mon May 28 16:21:40 2007 -0300 V4L/DVB (5704): Remove worthless references to obsolete MODULE_PARM macro. Remove the long-dead references to the obsolete MODULE_PARM macro. Given that the first one of those is actually misspelled as "MODULE_PARAM", it's clear that they can't have been doing any good. Acked-by: Thierry Merle Signed-off-by: Robert P. J. Day Signed-off-by: Mauro Carvalho Chehab commit 2c8a3a33558d3f5aa18b56eada66fbe712ee6bb7 Author: Dmitry Torokhov Date: Mon Jul 16 09:28:15 2007 -0300 V4L/DVB (5698): Input: drivers/media - switch to using input_dev->dev.parent In preparation for struct class_device -> struct device input core conversion switch to using input_dev->dev.parent when specifying device position in sysfs tree. Signed-off-by: Dmitry Torokhov Acked-by: Thierry Merle Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit afb758c4b03b17ff856f2bd58e488d152b342875 Author: Uwe Bugla Date: Sat May 26 07:56:29 2007 -0300 V4L/DVB (5701): Documentation/dvb/bt8xx.txt update This patch synchronizes the Documentation for bt8xx-based cards to the actual state of kernel 2.6.22-rc1. Signed-off-by: Uwe Bugla Signed-off-by: Manu Abraham Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit d577ee004d1bb4620ae43758ca7a0aa35319faaa Author: Aapo Tahkola Date: Tue May 8 18:33:52 2007 -0300 V4L/DVB (5696): M920x: add missing error handling to prevent syslog spamming Signed-off-by: Aapo Tahkola Signed-off-by: Mauro Carvalho Chehab commit 3ab3b69de52460ee676304aa773cd37b0b952905 Author: Aapo Tahkola Date: Tue May 8 18:23:38 2007 -0300 V4L/DVB (5695): M920x: enable second adapter on LifeView TV Walker Twin Enable second adapter on LifeView TV Walker Twin DVB-T USB2.0 Signed-off-by: Aapo Tahkola Signed-off-by: Mauro Carvalho Chehab commit 3847b22ab59a9110c9e7433ac75751070047280e Author: Aapo Tahkola Date: Tue May 8 18:21:47 2007 -0300 V4L/DVB (5694): M920x: fix for Dposh devices Make sure devices manufactured by Dposh are not affected by previous hw pid filtering changes Doing so might crash it. Signed-off-by: Aapo Tahkola Signed-off-by: Mauro Carvalho Chehab commit 55bbe5ea203373c07c10a9d1d5088dd013345027 Author: Aapo Tahkola Date: Tue May 8 12:56:54 2007 -0300 V4L/DVB (5693): M920x: second endpoint also needs to be changed to alt setting Spotted by Jeremy Nysen. Signed-off-by: Aapo Tahkola Signed-off-by: Mauro Carvalho Chehab commit 47f8df0fc0a5bd2e7e46ca438715ffa290051f72 Author: Aapo Tahkola Date: Tue May 8 12:03:55 2007 -0300 V4L/DVB (5692): M920x: attempt to fix hw pid filters on second endpoint Signed-off-by: Aapo Tahkola Signed-off-by: Mauro Carvalho Chehab commit 31bdc5dc7666aa2fe04c626cea30fe3c20cf481c Merge: 5cc97bf... a5f8967... Author: Linus Torvalds Date: Wed Jul 18 10:23:37 2007 -0700 Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 * 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6: [SPARC64]: Set vio->desc_buf to NULL after freeing. [SPARC]: Mark sparc and sparc64 as not having virt_to_bus [SPARC64]: Fix reset handling in VNET driver. [SPARC64]: Handle reset events in vio_link_state_change(). [SPARC64]: Handle LDC resets properly in domain-services driver. [SPARC64]: Massively simplify VIO device layer and support hot add/remove. [SPARC64]: Simplify VNET probing. [SPARC64]: Simplify VDC device probing. [SPARC64]: Add basic infrastructure for MD add/remove notification. commit 7cb47a14609eed6db2041fd1fe888027b2a3c3e0 Author: Daniel Gimpelevich Date: Thu May 17 18:10:17 2007 -0300 V4L/DVB (5685): Cx88: add support for ADS Tech Instant Video PCI Signed-off-by: Daniel Gimpelevich Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 8083c5200e74a5db11c9671bfc1bcaefe8c48737 Author: Dmitry Torokhov Date: Mon May 21 11:51:11 2007 -0300 V4L/DVB (5684): V4L: ir-kbd-i2c - switch to using msecs_to_jiffies() Signed-off-by: Dmitry Torokhov Signed-off-by: Mauro Carvalho Chehab commit 749823a06e74620ff3fefc75eab9d6fa473a9b39 Author: Dmitry Torokhov Date: Mon May 21 11:48:11 2007 -0300 V4L/DVB (5683): V4L: cx88 - switch to using msecs_to_jiffies() Signed-off-by: Dmitry Torokhov Signed-off-by: Mauro Carvalho Chehab commit b4ba788425f83e0b402a543c816a1cad01873699 Author: Dmitry Torokhov Date: Mon May 21 11:41:02 2007 -0300 V4L/DVB (5682): SAA7134 - switch to use msecs_to_jiffies() Signed-off-by: Dmitry Torokhov Signed-off-by: Mauro Carvalho Chehab commit c57032decdd07e531fc557a207c9ecd5eef9274d Author: Mauro Carvalho Chehab Date: Mon May 21 11:39:21 2007 -0300 V4L/DVB (5681): Correct aliases for STD/L and STD/Lc Some macros were using very weird names, like PAL/L (this std doesn't exist). Fixing it. Signed-off-by: Mauro Carvalho Chehab commit 783aa8fa1fe666a039edb784d9458647da97d28a Author: Akinobu Mita Date: Sun May 20 09:12:10 2007 -0300 V4L/DVB (5678): Zr364xx: fix return values This patch fixes several return value related problems in zr364xx. - return -ENOMEM instead of -ENODEV on out of memory - zr364xx checks video_register_device() error only when its return value is -1. But video_register_device() doesn't always return -1 on error. - If usb_register() returns error, module_init() wrongly returns 1: retval = usb_register(&zr364xx_driver) < 0; ... return retval; And it allows the module to be loaded. Because sys_init_module() doesn't see positive return value as error. Signed-off-by: Akinobu Mita Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit 1b9d313c38291c6d60f1fbf6a2bc62c484fdaa21 Author: Hans Verkuil Date: Fri May 18 16:18:17 2007 -0300 V4L/DVB (5674): Models 30012-30039 are for a low profile PVR250, not PVR150. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit e80666b87b7f832cad7f824c4ec5799b1c99fa5e Author: Hans Verkuil Date: Thu May 17 06:52:32 2007 -0300 V4L/DVB (5671): Autodetect new PVR150 low profile cards. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit f72ce644479fc06774367ed3c80d0f94e54d938b Author: Oliver Endriss Date: Sun May 13 23:25:57 2007 -0300 V4L/DVB (5669): Budget-av: Add support for EasyWatch DVB-S (0x1894:0x001b) Add support for Satelco EasyWatch PCI DVB-S card (subsystem 0x1894:0x001b). Signed-off-by: Oliver Endriss Signed-off-by: Mauro Carvalho Chehab commit 7b68814d797ae29095b7651e172c28a31ee37fda Author: Michael Krufky Date: Tue May 8 18:23:40 2007 -0300 V4L/DVB (5637): Cx88: kill core->pll_desc and core->pll_addr Now that dvb-pll is being used properly in all cx88-dvb instances, the cx88 driver no longer needs to store pll_desc nor pll_addr. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit b7754d74d20b701603eacf587a92ec6f71a302e1 Author: Trent Piepho Date: Tue May 8 18:05:16 2007 -0300 V4L/DVB (5636): Integrate all users of the fmd1216 tuner with dvb-pll Enhance the dvb-pll definition of the fmd1216 tuner by adding an init sequence and a sleep sequence. The init sequence sets the AGC control register to 0xa0, selecting the fast time constant and 112 dBuV take-over point. This the recommended value for DVB-T operation. The sleep sequence sets bit P4 (which is believed to turn the analog demodulator on), turns off the tuning voltage, and sets the AGC control register to 0x60 (external AGC voltage, the recommended value for analog operation). The existing dvb-pll users in the cx88 driver, listed below, will gain these init and sleep sequences. CX88_BOARD_HAUPPAUGE_HVR1100 Hauppauge WinTV-HVR1100 DVB-T/Hybrid CX88_BOARD_HAUPPAUGE_HVR1100LP Hauppauge WinTV-HVR1100 DVB-T/Hybrid (Low Profi CX88_BOARD_WINFAST_DTV2000H WinFast DTV2000 H CX88_BOARD_HAUPPAUGE_HVR3000 Hauppauge WinTV-HVR3000 TriMode Analog/DVB-S/DV CX88_BOARD_HAUPPAUGE_HVR1300 Hauppauge WinTV-HVR1300 DVB-T/Hybrid MPEG Encod This non-dvb-pll user in the cx88 driver should only gain the sleep sequence, as it already had an equivalent init sequence. The non-dvb-pll code for this user is removed. X88_BOARD_DNTV_LIVE_DVB_T_PRO digitalnow DNTV Live! DVB-T Pro In these saa7134 driver, these non-dvb-pll users are converted to use dvb-pll: SAA7134_BOARD_MD7134 Medion 7134 SAA7134_BOARD_ASUS_EUROPA2_HYBRID Asus Europa2 OEM The saa7134 functions philips_fmd1216_tuner_init(), philips_fmd1216_tuner_sleep(), and philips_fmd1216_tuner_set_params() are deleted and the dvb-pll versions are used. This should result in equivalent sleep, init, and tuning sequences being sent to the tuner. For the cxusb driver, only one board is effected: USB_PID_MEDION_MD95700 Medion MD95700 This board used dvb_usb_tuner_init_i2c() and dvb_usb_tuner_set_params_i2c() for init and tuning, respectively. These functions are effectively the same as the dvb-pll versions. They call a tuner pass control function defined at the dvb-usb level, but this does not matter, as this card does not have a tuner pass control function (only the dib3000mb does). This board will gain the sleep sequence, while init and tuning should be unchanged. Signed-off-by: Trent Piepho Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 4919c49278b3299c1373912dec9c3d9cf27ec56d Author: Aapo Tahkola Date: Tue May 8 17:36:40 2007 -0300 V4L/DVB (5628): Add support for A-LINK DTU dvb-t adapter Support for A-LINK DTU(m) is not included in this patch. Signed-off-by: Aapo Tahkola Acked-by: Antti Palosaari Signed-off-by: Mauro Carvalho Chehab commit e62a42090cdeaa6bbd3d22fa25309592c5eebbbd Author: Luca Olivetti Date: Mon May 7 16:57:57 2007 -0300 V4L/DVB (5626): Marked af9005 driver as experimental and fix dependencies Marked af9005 driver as experimental and add dependency for qt1010; Added a dependency on qt1010 in Kconfig; Corrected the experimental gain reduction of the mt2060 in case of strong signal (though it is code included in #ifdef 0). Signed-off-by: Luca Olivetti Signed-off-by: Mauro Carvalho Chehab commit af4e067e1dcf926d9523dff11e46c45fd9fa9da2 Author: Luca Olivetti Date: Mon May 7 15:19:32 2007 -0300 V4L/DVB (5625): Add support for the AF9005 demodulator from Afatech Signed-off-by: Luca Olivetti Signed-off-by: Manu Abraham Signed-off-by: Mauro Carvalho Chehab commit 79d3a8bede9350e2ff28b950341dcfead85ba04b Author: Michael Krufky Date: Wed May 9 14:52:52 2007 -0300 V4L/DVB (5652): Dibusb-mb: use dvb_attach for dib3000mb_attach convert calls to dib3000mb_attach to use dvb_attach Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit fbfee8684ff235c8cc4e8859913a017dabd59c03 Author: Michael Krufky Date: Wed May 9 15:58:17 2007 -0300 V4L/DVB (5651): Dibusb-mb: convert pll handling to properly use dvb-pll moved tda665x pll_init into dvb_pll_desc dvb_pll_tda665x.initdata convert handling of tda665x and tua6010xs to properly use dvb-pll Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 9bc7c04852194377fc276072359a19b5134250cc Author: Michael Krufky Date: Wed May 9 13:34:54 2007 -0300 V4L/DVB (5650): Umt-010: trivial whitespace cleanup Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit a3497135d829a7911b1b6a7e81ab78066cfa4131 Author: Michael Krufky Date: Wed May 9 13:33:21 2007 -0300 V4L/DVB (5649): Umt-010: convert tua6034 handling to properly use dvb-pll Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 890693925218501f7f7afc4cd6706fc76f395b91 Author: Michael Krufky Date: Wed May 9 11:49:24 2007 -0300 V4L/DVB (5648): Dvb/frontends: remove unnecessary #include's of "dvb-pll.h" These sources do not need to #include "dvb-pll.h" Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 480f75acbc1452c0fc7b2ee595bde17c18f798aa Author: Tony Wan Date: Fri May 11 11:33:50 2007 -0300 V4L/DVB (5647): Saa7134: enable ir-remote for 10moons TM300 Using Encore's key codes, we needn't add any additional key table. Signed-off-by: Tony Wan Signed-off-by: Mauro Carvalho Chehab commit aaccb82bdb93889987497b2b712c5160cdf79240 Author: Tony Wan Date: Thu May 10 12:16:47 2007 -0300 V4L/DVB (5646): V4l: saa7134: add support for 10moons TM300 card Support the 10moons TM300 TV card (so called TV Master 3), which is a 10moons saa7130 based board. Here not include features for the IR-remote. It has been tested using TVTIME. The card was auto-detected and all the input sources worked correct with sound. Signed-off-by: Tony Wan Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit c5f48367fe54c46805774eeea8e828de54a5ad7b Author: Thierry MERLE Date: Tue May 8 17:22:29 2007 -0300 V4L/DVB (5644): Usbvision: video_ioctl2 conversion The ioctl entry point, a big switch/case, is splitted in little functions. These functions are set as callbacks for the video_ioctl2 video4linux facility. This improves the driver memory consumption and enables the v4l1 compatibility as a side effect. Signed-off-by: Thierry MERLE Acked-by: Dwaine P. Garden Signed-off-by: Mauro Carvalho Chehab commit ea1f83cee96badc28d3f67ef29ac29c9d0eb0a1b Author: Thierry MERLE Date: Wed May 2 18:43:55 2007 -0300 V4L/DVB (5643): Usbvision: make common video and radio ioctls Radio and video ioctls are the same, delete the usbvision_do_radio_ioctl function add the special cases for radio in usbvision_v4l2_do_ioctl Signed-off-by: Thierry MERLE Signed-off-by: Mauro Carvalho Chehab commit 8c7189d1939f6e15c4ebc23a98b3b9f34bd004d7 Author: David Warman Date: Mon Apr 30 14:17:04 2007 -0300 V4L/DVB (5642): add comment that VO_MODE is also being set. usbvision_set_video_format: add comment that VO_MODE is also being set. Signed-off-by: David Warman Signed-off-by: Thierry MERLE Signed-off-by: Mauro Carvalho Chehab commit 9fe01e5c297e716c6b50166c3c032a6c07604e5b Author: David Warman Date: Mon Apr 30 14:12:19 2007 -0300 V4L/DVB (5641): change VideoNorm to NTSC for Belkin USB Videobus II Signed-off-by: David Warman Signed-off-by: Thierry MERLE Signed-off-by: Mauro Carvalho Chehab commit 9b98fd28b4a181cafaa5247a04d1be6d2ca7c863 Author: Michael Krufky Date: Mon May 7 01:48:56 2007 -0300 V4L/DVB (5635): Budget-av: convert philips sd1878 / tda8261 to use dvb-pll removed philips_sd1878_tda8261_tuner_set_params, using dvb_pll_attach, instead. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 8511df9ec2ef4c33a6b1e76527d5b47da8bc0bb6 Author: Michael Krufky Date: Mon May 7 01:34:36 2007 -0300 V4L/DVB (5634): Saa7134-dvb: convert philips td1316 handling to use dvb-pll removed mt352_aver777_tuner_calc_regs, using dvb_pll_attach, instead. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 4abe9f9d94e60303c30b1a9bbbc8e6532f6138cb Author: Michael Krufky Date: Sat May 5 12:15:57 2007 -0300 V4L/DVB (5633): Tuv1236d: move rf input switching code into dvb-pll This patch removes duplicate code from cx88-dvb and saa7134-dvb that handles rf input switching for the TUV1236d tuner. The functionality is added to dvb-pll, where all the other code that handles the TUV1236d is kept. Signed-off-by: Michael Krufky Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 77d675047062d514acdc1bbe9f84658b39f99abe Author: Michael Krufky Date: Sat May 5 12:05:39 2007 -0300 V4L/DVB (5632): Dvb-pll: pass dvb_frontend_parameters to generic set() function Rename dvb_pll_desc.setbw() to set(), and accept struct dvb_frontend_parameters instead of passing both freq and bandwidth, so that this may be used as a generic function. In order to do this, dvb_pll_configure must also be altered in the same manner, to take struct dvb_frontend_parameters instead of freq and bandwidth. Signed-off-by: Michael Krufky Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 900858ecb30c27ac94369052be650e25c0fd7d2a Author: Simon Arlott Date: Sun May 6 21:06:32 2007 -0300 V4L/DVB (5631): Dvb-core: Add level fixes to printk()s, plus spelling/grammer All the printks had missing level prefixes so I've fixed these too. Also fixed some grammer errors. Signed-off-by: Simon Arlott Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit ecf854df72847d90d5e44b6676a855677b5a33df Author: Trent Piepho Date: Sat May 5 20:11:32 2007 -0300 V4L/DVB (5629): Cx88: VP3054 support can't be a module when cx88 is compiled in If cx88 support is compiled into the kernel while vp3054 is left as a module, the kernel will fail to link. Adjust the existing "#if" code in cx88 so that it won't consider vp3054 to be supported in this case. It might make sense to move vp3054 selection into the "customisation" menu instead of a cx88 sub-option (though this is a cx88 feature, there is no extra chip involved). It might also make sense to use dvb_attach() to load vp3054 support. Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab commit 8573a9e6a8ed724b7e3074dc8762d4117ed0b3aa Author: Mauro Carvalho Chehab Date: Sun Apr 8 01:09:11 2007 -0300 V4L/DVB (5563a): Add experimental support for tea5761 tuner This driver were made based on tea5761 specs. Signed-off-by: Mauro Carvalho Chehab commit 5cc97bf2d8eaa6cab60727c3eba3e85e29062669 Merge: 826ea8f... dfdcdd4... Author: Linus Torvalds Date: Wed Jul 18 10:18:39 2007 -0700 Merge branch 'xen-upstream' of ssh://master.kernel.org/pub/scm/linux/kernel/git/jeremy/xen * 'xen-upstream' of ssh://master.kernel.org/pub/scm/linux/kernel/git/jeremy/xen: (44 commits) xen: disable all non-virtual drivers xen: use iret directly when possible xen: suppress abs symbol warnings for unused reloc pointers xen: Attempt to patch inline versions of common operations xen: Place vcpu_info structure into per-cpu memory xen: handle external requests for shutdown, reboot and sysrq xen: machine operations xen: add virtual network device driver xen: add virtual block device driver. xen: add the Xenbus sysfs and virtual device hotplug driver xen: Add grant table support xen: use the hvc console infrastructure for Xen console xen: hack to prevent bad segment register reload xen: lazy-mmu operations xen: Add support for preemption xen: SMP guest support xen: Implement sched_clock xen: Account for stolen time xen: ignore RW mapping of RO pages in pagetable_init xen: Complete pagetable pinning ... commit 826ea8f22cf612d534f33c492c98f7895043bfd1 Author: Tony Breeds Date: Wed Jul 18 16:17:48 2007 +1000 Revert "[POWERPC] Do firmware feature fixups after features are initialised" This reverts commit 5a26f6bbb767d7ad23311a1e81cfdd2bebefb855. The original patch causes boot failures when built with ppc64_defconfig. The quickest fix is to revert it while alterates are investigated. Signed-off-by: Tony Breeds Signed-off-by: Linus Torvalds commit 4f3731da16678026a564b1d7ae218131e4af6810 Author: Tony Breeds Date: Wed Jul 18 11:03:55 2007 +1000 Fix compile failure in arch/powerpc/kernel/pci-common.c This fixes the fallout from the recent powerpc merge (commit 489de30259e667d7bc47da9da44a0270b050cd97): CC arch/powerpc/kernel/pci-common.o arch/powerpc/kernel/pci-common.c:160: error: conflicting types for 'pcibios_add_platform_entries' include/linux/pci.h:889: error: previous declaration of 'pcibios_add_platform_entries' was here Signed-off-by: Tony Breeds Tested-by: Bret Towe Signed-off-by: Linus Torvalds commit dfdcdd42fdf63452ddd1bed6f49ae2a35dfb5d6c Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: disable all non-virtual drivers A domU Xen environment has no non-virtual drivers, so make sure they're all disabled at once. Signed-off-by: Jeremy Fitzhardinge Cc: Rusty Russell commit 9ec2b804e099e8a326369e6cccab10dee1d172ee Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: use iret directly when possible Most of the time we can simply use the iret instruction to exit the kernel, rather than having to use the iret hypercall - the only exception is if we're returning into vm86 mode, or from delivering an NMI (which we don't support yet). When running native, iret has the behaviour of testing for a pending interrupt atomically with re-enabling interrupts. Unfortunately there's no way to do this with Xen, so there's a window in which we could get a recursive exception after enabling events but before actually returning to userspace. This causes a problem: if the nested interrupt causes one of the task's TIF_WORK_MASK flags to be set, they will not be checked again before returning to userspace. This means that pending work may be left pending indefinitely, until the process enters and leaves the kernel again. The net effect is that a pending signal or reschedule event could be delayed for an unbounded amount of time. To deal with this, the xen event upcall handler checks to see if the EIP is within the critical section of the iret code, after events are (potentially) enabled up to the iret itself. If its within this range, it calls the iret critical section fixup, which adjusts the stack to deal with any unrestored registers, and then shifts the stack frame up to replace the previous invocation. Signed-off-by: Jeremy Fitzhardinge commit 600b2fc242992e552e0b4e24c8c1f084b341f39b Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: suppress abs symbol warnings for unused reloc pointers arch/i386/xen/xen-asm.S defines some small pieces of code which are used to implement a few paravirt_ops. They're designed so they can be used either in-place, or be inline patched into their callsites if there's enough space. Some of those operations need to make calls out (specifically, if you re-enable events [interrupts], and there's a pending event at that time). These calls need the call instruction to be relocated if the code is patched inline. In this case xen_foo_reloc is a section-relative symbol which points to xen_foo's required relocation. Other operations have no need of a relocation, and so their corresponding xen_bar_reloc is absolute 0. These are the cases which are triggering the warning. This patch adds those symbols to the list of safe abs symbols. Signed-off-by: Jeremy Fitzhardinge Cc: Adrian Bunk commit 6487673b8a858f99a5348e1078b3f5aec700f9e0 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: Attempt to patch inline versions of common operations This patchs adds the mechanism to allow us to patch inline versions of common operations. The implementations of the direct-access versions save_fl, restore_fl, irq_enable and irq_disable are now in assembler, and the same code is used for both out of line and inline uses. Signed-off-by: Jeremy Fitzhardinge Cc: Chris Wright Cc: Keir Fraser commit 60223a326fc8fa6e90e2c3fd28ae6de4a311d731 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: Place vcpu_info structure into per-cpu memory An experimental patch for Xen allows guests to place their vcpu_info structs anywhere. We try to use this to place the vcpu_info into the PDA, which allows direct access. If this works, then switch to using direct access operations for irq_enable, disable, save_fl and restore_fl. Signed-off-by: Jeremy Fitzhardinge Cc: Chris Wright Cc: Keir Fraser commit 3e2b8fbeec8f005672f2a2e862fb9c26a0bafedc Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: handle external requests for shutdown, reboot and sysrq The guest domain can be asked to shutdown or reboot itself, or have a sysrq key injected, via xenbus. This patch adds a watcher for those events, and does the appropriate action. Signed-off-by: Jeremy Fitzhardinge Cc: Chris Wright commit fefa629abebe328cf6d07f99fe5796dbfc3e4981 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:07 2007 -0700 xen: machine operations Make the appropriate hypercalls to halt and reboot the virtual machine. Signed-off-by: Jeremy Fitzhardinge Acked-by: Chris Wright commit 0d160211965b79de989cf2d170985abeb8da5ec6 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: add virtual network device driver The network device frontend driver allows the kernel to access network devices exported exported by a virtual machine containing a physical network device driver. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Acked-by: Jeff Garzik Cc: Ian Pratt Cc: Christian Limpach Cc: Stephen Hemminger Cc: Christoph Hellwig Cc: Rusty Russell Cc: Herbert Xu Cc: Keir Fraser Cc: netdev@vger.kernel.org commit 9f27ee595038653ddf8bca871200d39247d6f4fc Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: add virtual block device driver. The block device frontend driver allows the kernel to access block devices exported exported by a virtual machine containing a physical block device driver. Signed-off-by: Ian Pratt Signed-off-by: Christian Limpach Signed-off-by: Chris Wright Cc: Arjan van de Ven Cc: Greg KH Cc: Jens Axboe commit 4bac07c993d03434ea902d3d4290d9e45944b66c Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: add the Xenbus sysfs and virtual device hotplug driver This communicates with the machine control software via a registry residing in a controlling virtual machine. This allows dynamic creation, destruction and modification of virtual device configurations (network devices, block devices and CPUS, to name some examples). [ Greg, would you mind giving this a review? Thanks -J ] Signed-off-by: Ian Pratt Signed-off-by: Christian Limpach Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Greg KH commit ad9a86121f5a374b48ce2924f8a9d7e94a04db27 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: Add grant table support Add Xen 'grant table' driver which allows granting of access to selected local memory pages by other virtual machines and, symmetrically, the mapping of remote memory pages which other virtual machines have granted access to. This driver is a prerequisite for many of the Xen virtual device drivers, which grant the 'device driver domain' restricted and temporary access to only those memory pages that are currently involved in I/O operations. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ian Pratt Signed-off-by: Christian Limpach Signed-off-by: Chris Wright commit b536b4b9623084d86f2b1f19cb44a2d6d74f00bf Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: use the hvc console infrastructure for Xen console Implement a Xen back-end for hvc console. * * * Add early printk support via hvc console, enable using "earlyprintk=xen" on the kernel command line. From: Gerd Hoffmann Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Acked-by: Ingo Molnar Acked-by: Olof Johansson commit 8b84ad942b534f8faeb34b68f0f7277ea375fed0 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: hack to prevent bad segment register reload The hypervisor saves and restores the segment registers as part of the state is saves while context switching. If, during a context switch, the next process doesn't use the TLS segments, it invalidates the GDT entry, causing the segment register reload to fault. This fault effectively doubles the cost of a context switch. This patch is a band-aid workaround which clears the usermode %gs after it has been saved for the previous process, but before it gets reloaded for the next, and it avoids having the hypervisor attempt to erroneously reload it. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright commit d66bf8fcf3fce058a1cd164a7c8ee6093fdf039c Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: lazy-mmu operations This patch uses the lazy-mmu hooks to batch mmu operations where possible. This is primarily useful for batching operations applied to active pagetables, which happens during mprotect, munmap, mremap and the like (mmap does not do bulk pagetable operations, so it isn't helped). Signed-off-by: Jeremy Fitzhardinge Acked-by: Chris Wright commit f120f13ea0dbb0b0d6675683d5f6faea71277e65 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: Add support for preemption Add Xen support for preemption. This is mostly a cleanup of existing preempt_enable/disable calls, or just comments to explain the current usage. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright commit f87e4cac4f4e940b328d3deb5b53e642e3881f43 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:06 2007 -0700 xen: SMP guest support This is a fairly straightforward Xen implementation of smp_ops. Xen has its own IPI mechanisms, and has no dependency on any APIC-based IPI. The smp_ops hooks and the flush_tlb_others pv_op allow a Xen guest to avoid all APIC code in arch/i386 (the only apic operation is a single apic_read for the apic version number). One subtle point which needs to be addressed is unpinning pagetables when another cpu may have a lazy tlb reference to the pagetable. Xen will not allow an in-use pagetable to be unpinned, so we must find any other cpus with a reference to the pagetable and get them to shoot down their references. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Benjamin LaHaise Cc: Ingo Molnar Cc: Andi Kleen commit ab55028886dd1dd54585f22bf19a00eb23869340 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: Implement sched_clock Implement xen_sched_clock, which returns the number of ns the current vcpu has been actually in an unstolen state (ie, running or blocked, vs runnable-but-not-running, or offline) since boot. Signed-off-by: Jeremy Fitzhardinge Acked-by: Chris Wright Cc: john stultz commit f91a8b447b9af64f589f6e13fec7f09b5927563d Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: Account for stolen time This patch accounts for the time stolen from our VCPUs. Stolen time is time where a vcpu is runnable and could be running, but all available physical CPUs are being used for something else. This accounting gets run on each timer interrupt, just as a way to get it run relatively often, and when interesting things are going on. Stolen time is not really used by much in the kernel; it is reported in /proc/stats, and that's about it. Signed-off-by: Jeremy Fitzhardinge Acked-by: Chris Wright Cc: john stultz Cc: Rik van Riel commit 9a4029fd3409eb224eb62c32d9792071382694ec Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: ignore RW mapping of RO pages in pagetable_init When setting up the initial pagetable, which includes mappings of all low physical memory, ignore a mapping which tries to set the RW bit on an RO pte. An RO pte indicates a page which is part of the current pagetable, and so it cannot be allowed to become RW. Once xen_pagetable_setup_done is called, set_pte reverts to its normal behaviour. Signed-off-by: Jeremy Fitzhardinge Acked-by: Chris Wright Cc: ebiederm@xmission.com (Eric W. Biederman) commit f4f97b3ea90130520afb478cbc2918be2b6587b8 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: Complete pagetable pinning Xen requires all active pagetables to be marked read-only. When the base of the pagetable is loaded into %cr3, the hypervisor validates the entire pagetable and only allows the load to proceed if it all checks out. This is pretty slow, so to mitigate this cost Xen has a notion of pinned pagetables. Pinned pagetables are pagetables which are considered to be active even if no processor's cr3 is pointing to is. This means that it must remain read-only and all updates are validated by the hypervisor. This makes context switches much cheaper, because the hypervisor doesn't need to revalidate the pagetable each time. This also adds a new paravirt hook which is called during setup once the zones and memory allocator have been initialized. When the init_mm pagetable is first built, the struct page array does not yet exist, and so there's nowhere to put he init_mm pagetable's PG_pinned flags. Once the zones are initialized and the struct page array exists, we can set the PG_pinned flags for those pages. This patch also adds the Xen support for pte pages allocated out of highmem (highpte) by implementing xen_kmap_atomic_pte. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Zach Amsden commit c85b04c3749507546f6d5868976e4793e35c2ec0 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: add pinned page flag Add a new definition for PG_owner_priv_1 to define PG_pinned on Xen pagetable pages. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright commit e738fca8d7dffec30eeee231c38f128eed56c8c8 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: configuration Put config options for Xen after the core pieces are in place. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright commit 15c84731d647c34d1491793fa6be96f5de3432eb Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: time implementation Xen maintains a base clock which measures nanoseconds since system boot. This is provided to guests via a shared page which contains a base time in ns, a tsc timestamp at that point and tsc frequency parameters. Guests can compute the current time by reading the tsc and using it to extrapolate the current time from the basetime. The hypervisor makes sure that the frequency parameters are updated regularly, paricularly if the tsc changes rate or stops. This is implemented as a clocksource, so the interface to the rest of the kernel is a simple clocksource which simply returns the current time directly in nanoseconds. Xen also provides a simple timer mechanism, which allows a timeout to be set in the future. When that time arrives, a timer event is sent to the guest. There are two timer interfaces: - An old one which also delivers a stream of (unused) ticks at 100Hz, and on the same event, the actual timer events. The 100Hz ticks cause a lot of spurious wakeups, but are basically harmless. - The new timer interface doesn't have the 100Hz ticks, and can also fail if the specified time is in the past. This code presents the Xen timer as a clockevent driver, and uses the new interface by preference. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Ingo Molnar Cc: Thomas Gleixner commit e46cdb66c8fc1c8d61cfae0f219ff47ac4b9d531 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:05 2007 -0700 xen: event channels Xen implements interrupts in terms of event channels. Each guest domain gets 1024 event channels which can be used for a variety of purposes, such as Xen timer events, inter-domain events, inter-processor events (IPI) or for real hardware IRQs. Within the kernel, we map the event channels to IRQs, and implement the whole interrupt handling using a Xen irq_chip. Rather than setting NR_IRQ to 1024 under PARAVIRT in order to accomodate Xen, we create a dynamic mapping between event channels and IRQs. Ideally, Linux will eventually move towards dynamically allocating per-irq structures, and we can use a 1:1 mapping between event channels and irqs. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Ingo Molnar Cc: Eric W. Biederman commit 3b827c1b3aadf3adb4c602d19863f2d24e7cbc18 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 xen: virtual mmu Xen pagetable handling, including the machinery to implement direct pagetables. Xen presents the real CPU's pagetables directly to guests, with no added shadowing or other layer of abstraction. Naturally this means the hypervisor must maintain close control over what the guest can put into the pagetable. When the guest modifies the pte/pmd/pgd, it must convert its domain-specific notion of a "physical" pfn into a global machine frame number (mfn) before inserting the entry into the pagetable. Xen will check to make sure the domain is allowed to create a mapping of the given mfn. Xen also requires that all mappings the guest has of its own active pagetable are read-only. This is relatively easy to implement in Linux because all pagetables share the same pte pages for kernel mappings, so updating the pte in one pagetable will implicitly update the mapping in all pagetables. Normally a pagetable becomes active when you point to it with cr3 (or the Xen equivalent), but when you do so, Xen must check the whole pagetable for correctness, which is clearly a performance problem. Xen solves this with pinning which keeps a pagetable effectively active even if its currently unused, which means that all the normal update rules are enforced. This means that it need not revalidate the pagetable when loading cr3. This patch has a first-cut implementation of pinning, but it is more fully implemented in a later patch. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright commit 5ead97c84fa7d63a6a7a2f4e9f18f452bd109045 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 xen: Core Xen implementation This patch is a rollup of all the core pieces of the Xen implementation, including: - booting and setup - pagetable setup - privileged instructions - segmentation - interrupt flags - upcalls - multicall batching BOOTING AND SETUP The vmlinux image is decorated with ELF notes which tell the Xen domain builder what the kernel's requirements are; the domain builder then constructs the address space accordingly and starts the kernel. Xen has its own entrypoint for the kernel (contained in an ELF note). The ELF notes are set up by xen-head.S, which is included into head.S. In principle it could be linked separately, but it seems to provoke lots of binutils bugs. Because the domain builder starts the kernel in a fairly sane state (32-bit protected mode, paging enabled, flat segments set up), there's not a lot of setup needed before starting the kernel proper. The main steps are: 1. Install the Xen paravirt_ops, which is simply a matter of a structure assignment. 2. Set init_mm to use the Xen-supplied pagetables (analogous to the head.S generated pagetables in a native boot). 3. Reserve address space for Xen, since it takes a chunk at the top of the address space for its own use. 4. Call start_kernel() PAGETABLE SETUP Once we hit the main kernel boot sequence, it will end up calling back via paravirt_ops to set up various pieces of Xen specific state. One of the critical things which requires a bit of extra care is the construction of the initial init_mm pagetable. Because Xen places tight constraints on pagetables (an active pagetable must always be valid, and must always be mapped read-only to the guest domain), we need to be careful when constructing the new pagetable to keep these constraints in mind. It turns out that the easiest way to do this is use the initial Xen-provided pagetable as a template, and then just insert new mappings for memory where a mapping doesn't already exist. This means that during pagetable setup, it uses a special version of xen_set_pte which ignores any attempt to remap a read-only page as read-write (since Xen will map its own initial pagetable as RO), but lets other changes to the ptes happen, so that things like NX are set properly. PRIVILEGED INSTRUCTIONS AND SEGMENTATION When the kernel runs under Xen, it runs in ring 1 rather than ring 0. This means that it is more privileged than user-mode in ring 3, but it still can't run privileged instructions directly. Non-performance critical instructions are dealt with by taking a privilege exception and trapping into the hypervisor and emulating the instruction, but more performance-critical instructions have their own specific paravirt_ops. In many cases we can avoid having to do any hypercalls for these instructions, or the Xen implementation is quite different from the normal native version. The privileged instructions fall into the broad classes of: Segmentation: setting up the GDT and the GDT entries, LDT, TLS and so on. Xen doesn't allow the GDT to be directly modified; all GDT updates are done via hypercalls where the new entries can be validated. This is important because Xen uses segment limits to prevent the guest kernel from damaging the hypervisor itself. Traps and exceptions: Xen uses a special format for trap entrypoints, so when the kernel wants to set an IDT entry, it needs to be converted to the form Xen expects. Xen sets int 0x80 up specially so that the trap goes straight from userspace into the guest kernel without going via the hypervisor. sysenter isn't supported. Kernel stack: The esp0 entry is extracted from the tss and provided to Xen. TLB operations: the various TLB calls are mapped into corresponding Xen hypercalls. Control registers: all the control registers are privileged. The most important is cr3, which points to the base of the current pagetable, and we handle it specially. Another instruction we treat specially is CPUID, even though its not privileged. We want to control what CPU features are visible to the rest of the kernel, and so CPUID ends up going into a paravirt_op. Xen implements this mainly to disable the ACPI and APIC subsystems. INTERRUPT FLAGS Xen maintains its own separate flag for masking events, which is contained within the per-cpu vcpu_info structure. Because the guest kernel runs in ring 1 and not 0, the IF flag in EFLAGS is completely ignored (and must be, because even if a guest domain disables interrupts for itself, it can't disable them overall). (A note on terminology: "events" and interrupts are effectively synonymous. However, rather than using an "enable flag", Xen uses a "mask flag", which blocks event delivery when it is non-zero.) There are paravirt_ops for each of cli/sti/save_fl/restore_fl, which are implemented to manage the Xen event mask state. The only thing worth noting is that when events are unmasked, we need to explicitly see if there's a pending event and call into the hypervisor to make sure it gets delivered. UPCALLS Xen needs a couple of upcall (or callback) functions to be implemented by each guest. One is the event upcalls, which is how events (interrupts, effectively) are delivered to the guests. The other is the failsafe callback, which is used to report errors in either reloading a segment register, or caused by iret. These are implemented in i386/kernel/entry.S so they can jump into the normal iret_exc path when necessary. MULTICALL BATCHING Xen provides a multicall mechanism, which allows multiple hypercalls to be issued at once in order to mitigate the cost of trapping into the hypervisor. This is particularly useful for context switches, since the 4-5 hypercalls they would normally need (reload cr3, update TLS, maybe update LDT) can be reduced to one. This patch implements a generic batching mechanism for hypercalls, which gets used in many places in the Xen code. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Ian Pratt Cc: Christian Limpach Cc: Adrian Bunk commit a42089dd358a7673a0a23126589a9029e57c2049 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 xen: Add Xen interface header files Add Xen interface header files. These are taken fairly directly from the Xen tree, but somewhat rearranged to suit the kernel's conventions. Define macros and inline functions for doing hypercalls into the hypervisor. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ian Pratt Signed-off-by: Christian Limpach Signed-off-by: Chris Wright commit 24037a8b69dbf15bfed8fd42a2a2e442d7b0395b Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 Add nosegneg capability to the vsyscall page notes Add the "nosegneg" fake capabilty to the vsyscall page notes. This is used by the runtime linker to select a glibc version which then disables negative-offset accesses to the thread-local segment via %gs. These accesses require emulation in Xen (because segments are truncated to protect the hypervisor address space) and avoiding them provides a measurable performance boost. Signed-off-by: Ian Pratt Signed-off-by: Christian Limpach Signed-off-by: Chris Wright Signed-off-by: Jeremy Fitzhardinge Acked-by: Zachary Amsden Cc: Roland McGrath Cc: Ulrich Drepper commit 688340ea34c61ad12473ccd837325b59aada9a93 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 Add a sched_clock paravirt_op The tsc-based get_scheduled_cycles interface is not a good match for Xen's runstate accounting, which reports everything in nanoseconds. This patch replaces this interface with a sched_clock interface, which matches both Xen and VMI's requirements. In order to do this, we: 1. replace get_scheduled_cycles with sched_clock 2. hoist cycles_2_ns into a common header 3. update vmi accordingly One thing to note: because sched_clock is implemented as a weak function in kernel/sched.c, we must define a real function in order to override this weak binding. This means the usual paravirt_ops technique of using an inline function won't work in this case. Signed-off-by: Jeremy Fitzhardinge Cc: Zachary Amsden Cc: Dan Hecht Cc: john stultz commit d572929cdd12a60732c3522f7cf011bfa29165cf Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 paravirt: helper to disable all IO space In a virtual environment, device drivers such as legacy IDE will waste quite a lot of time probing for their devices which will never appear. This helper function allows a paravirt implementation to lay claim to the whole iomem and ioport space, thereby disabling all device drivers trying to claim IO resources. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Rusty Russell commit 5f4352fbffd6c45123dbce9e195efd54df4e177e Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 Allocate and free vmalloc areas Allocate/release a chunk of vmalloc address space: alloc_vm_area reserves a chunk of address space, and makes sure all the pagetables are constructed for that address range - but no pages. free_vm_area releases the address space range. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ian Pratt Signed-off-by: Christian Limpach Signed-off-by: Chris Wright Cc: "Jan Beulich" Cc: "Andi Kleen" commit bdef40a6af64a0140a65df49bf504124d57094a9 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:04 2007 -0700 paravirt: export __supported_pte_mask __supported_pte_mask is needed when constructing pte values. Xen device drivers need to do this to make mappings of foreign pages (ie, pages granted to us by other domains). Signed-off-by: Jeremy Fitzhardinge commit c70df74376c1e29a04e07e23dd3f4c384d6166dd Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 paravirt: make siblingmap functions visible Paravirt implementations need to set the sibling map on new cpus. Signed-off-by: Jeremy Fitzhardinge commit 724faa89ccd8fae65f3d41a47b0e1034cf07918b Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 paravirt: unstatic smp_store_cpu_info Paravirt implementations need to store cpu info when bringing up cpus. Signed-off-by: Jeremy Fitzhardinge commit 53787013248f52af81d99f63454e5a5cf34d6f12 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 paravirt: unstatic leave_mm Make globally leave_mm visible, specifically so that Xen can use it to shoot-down lazy uses of cr3. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright commit 03f0c2f950f813e3b26c56ed041ba170479d479c Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 paravirt: increase IRQ limit When running with CONFIG_PARAVIRT, we may want lots of IRQs even if there's no IO APIC. Signed-off-by: Jeremy Fitzhardinge Cc: "Eric W. Biederman" commit 6996d3b63fd9a64341bc80dad1b556fd3eb81272 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 paravirt: add a hook for once the allocator is ready Add a hook so that the paravirt backend knows when the allocator is ready. This is useful for the obvious reason that the allocator is available, but the other side-effect of having the bootmem allocator available is that each page now has an associated "struct page". Signed-off-by: Jeremy Fitzhardinge commit fdb4c338c8d1d494e17c3422a3ea2129f6791596 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 paravirt: add an "mm" argument to alloc_pt It's useful to know which mm is allocating a pagetable. Xen uses this to determine whether the pagetable being added to is pinned or not. Signed-off-by: Jeremy Fitzhardinge commit 810bab448e563ffd1718d78e9a3756806b626acc Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 use elfnote.h to generate vsyscall notes. Use existing elfnote.h to generate vsyscall notes, rather than doing it locally. Changes elfnote.h a bit to suit, since this is the first asm user, and it wasn't quite right. Signed-off-by: Jeremy Fitzhardinge Cc: "Eric W. Biederman" Cc: Roland McGrath Cc: Andrew Morton commit 86313c488a6848b7ec2ba04e74f25f79dd32a0b7 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:03 2007 -0700 usermodehelper: Tidy up waiting Rather than using a tri-state integer for the wait flag in call_usermodehelper_exec, define a proper enum, and use that. I've preserved the integer values so that any callers I've missed should still work OK. Signed-off-by: Jeremy Fitzhardinge Cc: James Bottomley Cc: Randy Dunlap Cc: Christoph Hellwig Cc: Andi Kleen Cc: Paul Mackerras Cc: Johannes Berg Cc: Ralf Baechle Cc: Bjorn Helgaas Cc: Joel Becker Cc: Tony Luck Cc: Kay Sievers Cc: Srivatsa Vaddagiri Cc: Oleg Nesterov Cc: David Howells commit 10a0a8d4e3f6bf2d077f94344441909abe670f5a Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:02 2007 -0700 Add common orderly_poweroff() Various pieces of code around the kernel want to be able to trigger an orderly poweroff. This pulls them together into a single implementation. By default the poweroff command is /sbin/poweroff, but it can be set via sysctl: kernel/poweroff_cmd. This is split at whitespace, so it can include command-line arguments. This patch replaces four other instances of invoking either "poweroff" or "shutdown -h now": two sbus drivers, and acpi thermal management. sparc64 has its own "powerd"; still need to determine whether it should be replaced by orderly_poweroff(). Signed-off-by: Jeremy Fitzhardinge Acked-by: Len Brown Signed-off-by: Chris Wright Cc: Andrew Morton Cc: Randy Dunlap Cc: Andi Kleen Cc: Al Viro Cc: Arnd Bergmann Cc: David S. Miller commit 0ab4dc92278a0f3816e486d6350c6652a72e06c8 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:02 2007 -0700 usermodehelper: split setup from execution Rather than having hundreds of variations of call_usermodehelper for various pieces of usermode state which could be set up, split the info allocation and initialization from the actual process execution. This means the general pattern becomes: info = call_usermodehelper_setup(path, argv, envp); /* basic state */ call_usermodehelper_(info, stuff...); /* extra state */ call_usermodehelper_exec(info, wait); /* run process and free info */ This patch introduces wrappers for all the existing calling styles for call_usermodehelper_*, but folds their implementations into one. Signed-off-by: Jeremy Fitzhardinge Cc: Andi Kleen Cc: Rusty Russell Cc: David Howells Cc: Bj?rn Steinbrink Cc: Randy Dunlap commit d84d1cc7647c7e4f77d517e2d87b4a106a0420d9 Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:02 2007 -0700 add argv_split() argv_split() is a helper function which takes a string, splits it at whitespace, and returns a NULL-terminated argv vector. This is deliberately simple - it does no quote processing of any kind. [ Seems to me that this is something which is already being done in the kernel, but I couldn't find any other implementations, either to steal or replace. Keep an eye out. ] Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Andrew Morton Cc: Randy Dunlap commit 1e66df3ee301209f4a38df097d7cc5cb9b367a3f Author: Jeremy Fitzhardinge Date: Tue Jul 17 18:37:02 2007 -0700 add kstrndup Add a kstrndup function, modelled on strndup. Like strndup this returns a string copied into its own allocated memory, but it copies no more than the specified number of bytes from the source. Remove private strndup() from irda code. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Chris Wright Cc: Andrew Morton Cc: Randy Dunlap Cc: YOSHIFUJI Hideaki Cc: Akinobu Mita Cc: Arnaldo Carvalho de Melo Cc: Al Viro Cc: Panagiotis Issaris Cc: Rene Scharfe commit 8b4a40809e5330c9da5d20107d693d92d73b31dc Author: Maciej W. Rozycki Date: Wed Jul 18 00:49:11 2007 -0700 zs: move to the serial subsystem This is a reimplementation of the zs driver for the serial subsystem. Any resemblance to the old driver is purely coincidential. ;-) I do hope I got the handling of modem lines right -- better do not tackle me about the issue unless you feel too good... Any users of the old driver: please note the numbers of the serial lines have now been swapped, i.e. ttyS0 <-> ttyS1 and ttyS2 <-> ttyS3. It has to do with the modem lines mentioned above; basically the port A in a given chip has to be initialised before the port B if you want to use the latter as the serial console (which is usually the case), as operations on modem lines of the serial line associated with the port B access both ports (see the comment at the top of the driver for the details of wiring used). Please update your scripts. This is also the reason each SCC now requests an IRQ once only (as seen in "/proc/interrupts") -- the handler takes care of both ports at once as the line associated with the port B has to take status update interrupts from both ports (and yet the line of the port A takes its own for itself too). The old driver never got it right... Signed-off-by: Maciej W. Rozycki Cc: Ralf Baechle Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds commit b187f180cc942e50007aa039f8e3a620ee5f3171 Author: Yinghai Lu Date: Wed Jul 18 00:49:10 2007 -0700 serial: add early_serial_setup() back to header file early_serial_setup was removed from serial.h, but forgot to put in serial_8250.h Signed-off-by: Yinghai Lu Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds commit 04e08d0e9b936b91e761454b3134e260c4f50696 Author: Arnd Bergmann Date: Wed Jul 18 00:49:09 2007 -0700 fbdev: make fb_append_extra_logo() depend on fb=y We can't show the extra logo from boot code if FB is built as a module. Make the FB_LOGO_EXTRA depend on FB=y. Signed-off-by: Arnd Bergmann Cc: Al Viro Cc: "Antonino A. Daplas" Acked-by: Geert Uytterhoeven Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds commit 851a8a7fd451db3dcd5d44d784083f0f66b24d57 Author: Jesper Juhl Date: Wed Jul 18 00:49:08 2007 -0700 dm: fix memory leak in dm_create_persistent() when starting metadata update thread fails If, in dm_create_persistent(), the call to create_singlethread_workqueue() fails then we'll return without freeing the memory allocated to 'ps', thus leaking sizeof(struct pstore) bytes. This patch fixes the leak. Signed-off-by: Jesper Juhl Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds commit add0b43ca67bf281ef7ac8ab47e9ee7b2d97a69f Author: Paul Mundt Date: Wed Jul 18 18:39:45 2007 +0900 UBI: fix compile warning cdev.c whines in current git: drivers/mtd/ubi/cdev.c: In function `major_to_device': drivers/mtd/ubi/cdev.c:67: warning: control reaches end of non-void function Shut it up. Signed-off-by: Paul Mundt Signed-off-by: Artem Bityutskiy commit 784c145444e7dd58ae740d406155b72ac658f151 Author: Artem Bityutskiy Date: Wed Jul 18 13:42:10 2007 +0300 UBI: fix error handling in erase worker Do not switch to read-only mode in case of -EINTR and some other obvious cases. Switch to RO mode only when we do not know what is the error. Reported-by: Vinit Agnihotri Signed-off-by: Artem Bityutskiy commit 63b6c1ed56f69fdd35122dc591164587e3407ba0 Author: Artem Bityutskiy Date: Tue Jul 17 15:04:20 2007 +0300 UBI: fix comments Signed-off-by: Artem Bityutskiy commit 503990ebb21e5aabe497a3eb1d39bef0bbc1be6f Author: Artem Bityutskiy Date: Wed Jul 11 16:03:29 2007 +0300 UBI: remove unneeded error checks Pointed to by viro. Signed-off-by: Artem Bityutskiy commit 2db61c95c03d08bb885c87a816540e75190c924a Author: Fernando Luis Vázquez Cao Date: Wed Jul 11 17:11:45 2007 +0900 UBI: cleanup usage of try_module_get The use of try_module_get(THIS_MODULE) in ubi_get_device_info does not offer real protection against unexpected driver unloads, since we could be preempted before try_modules_get gets executed. It is the caller who should manipulate the refcounts. Besides, ubi_get_device_info is an exported symbol which guarantees protection when accessed through symbol_get. Signed-off-by: Fernando Luis Vazquez Cao Signed-off-by: Artem Bityutskiy commit d08c3b78b8c46a01b8fa59037a0d9fbb777fb465 Author: Vinit Agnihotri Date: Tue Jul 10 13:04:59 2007 +0300 UBI: fix overflow bug I was experiencing overflows in multiplications for volume->used_bytes in vmt.c & vtbl.c, while creating & resizing large volumes. vol->used_bytes is long long however its 2 operands vol->used_ebs & vol->usable_leb_size are int. So their multiplication for larger values causes integer overflows. Typecasting them solves the problem. My machine & flash details: 64Bit dual-core AMD opteron, 1 GB RAM, linux 2.6.18.3. mtd size = 6GB, volume size= 5GB, peb_size = 4MB. heres patch which does the fix. Signed-off-by: Vinit Agnihotri Signed-off-by: Artem Bityutskiy commit 2f3cdb55eef4fa1398965e893f731fb6e6312d34 Author: Artem Bityutskiy Date: Fri Jul 6 14:38:46 2007 +0300 UBI: bugfix in max_sqnum calculation Do not zero max_sqnum after a new volume has been found. Signed-off-by: Artem Bityutskiy commit 76eafe479ec30dd72b8cf209c4f576eac3c93112 Author: Brijesh Singh Date: Fri Jul 6 14:35:43 2007 +0300 UBI: bugfix in sqnum calculation Hi,I came across problem of having two leb with same sequence no.This happens when we continuously write one block again and again and reboot machine before background thread erases those blocks. The problem here was,when we find two blocks with same sequence no,we take the higher one,but we were not updating max seq no,so next block may have the same seqnum. This patch solves this problem. Signed-off-by: Brijesh Singh Signed-off-by: Artem Bityutskiy commit 2f176f79877937082ce052977e552a75e23a73d1 Author: Brijesh Singh Date: Thu Jul 5 15:07:35 2007 +0530 UBI: fix signed-unsigned multiplication There is signed multiplication assigned to unsigned ei.addr in io.c. This causes wrong addresses for big multiplication.This patch solves the problem. Signed-off-by: Brijesh Singh Signed-off-by: Artem Bityutskiy commit 84a925806210e002fab29966c09b9c92f382a79d Author: Artem Bityutskiy Date: Wed Jul 4 16:16:51 2007 +0300 UBI: fix bug in atomic_leb_change() atomic_leb_change() is only allowed for dynamic volumes, so set the volume type correctly. Signed-off-by: Artem Bityutskiy commit a6ded48e34f803fcbb42719cee452d1f18938ec7 Author: Vinit Agnihotri Date: Wed Jul 4 16:35:56 2007 +0300 UBI: fix message Increase UBI devices couter after the message, not before. Signed-off-by: Vinit Agnihotri Signed-off-by: Artem Bityutskiy commit b89044bfa06e8a9a82094fda031cc6d4e8d4a0b0 Author: Artem Bityutskiy Date: Mon Jun 18 16:29:30 2007 +0300 UBI: fix debugging stuff Do not check volumes which are currently in use because thay may be in inconsistent state. Signed-off-by: Artem Bityutskiy commit 94784d916458d51043ba76849b9beaf330baef2f Author: Artem Bityutskiy Date: Mon Jun 18 12:06:30 2007 +0300 UBI: bugfix in error path When volume creation fails, we have to set ubi->volumes[vol_id] back to NULL. This patch also tweaks some debugging stuff. Signed-off-by: Artem Bityutskiy commit 7753f1692f53d82b4cc08084462b0fd2803c1f04 Author: Vignesh Babu Date: Tue Jun 12 10:31:05 2007 +0530 UBI: use is_power_of_2() Replacing (n & (n-1)) in the context of power of 2 checks with is_power_of_2 Signed-off-by: Vignesh Babu Signed-off-by: Artem Bityutskiy commit d7f0c4dc31f1297a613f1e61a7d682dc9a5e859a Author: Vinit Agnihotri Date: Fri Jun 15 15:31:22 2007 +0530 UBI: fix freeing ubi->vtbl while unloading ubi->vtbl is allocated using vmalloc() in vtbl.c empty_create_lvol(), but it is freed in build.c with kfree() Signed-off-by: Vinit Agnihotri Signed-off-by: Artem Bityutskiy commit 21600546ab84e451adb88771b52b64b97866a444 Author: Artem Bityutskiy Date: Tue May 22 12:23:21 2007 +0300 UBI: fix MAINTAINERS Fix UBI git tree URL. Signed-off-by: Artem Bityutskiy commit a443db48e05a8d2d8db0a17409655c58da65a35e Author: Artem Bityutskiy Date: Mon May 21 20:26:05 2007 +0300 UBI: bugfix in ubi_leb_change() Do not call 'ubi_wl_put_peb()' if the LEB was unmapped. Reported-by: Gabor Loki Signed-off-by: Artem Bityutskiy commit 3261ebd7d4194ff30d0eae7ba8d937dcccf7235d Author: Christoph Hellwig Date: Mon May 21 17:41:46 2007 +0300 UBI: kill homegrown endian macros Kill UBI's homegrown endianess handling and replace it with the standard kernel endianess handling. Signed-off-by: Christoph Hellwig Signed-off-by: Artem Bityutskiy commit bf07803a6827ef8d4c9d840a1de800ba36db0213 Author: Christoph Hellwig Date: Thu May 17 16:32:10 2007 +0200 UBI: cleanup ioctl handling - don't do access_ok + get/put user but use the proper macro - remove useless checks Signed-off-by: Christoph Hellwig Signed-off-by: Artem Bityutskiy commit 16d8cd7ce408a20db1ab192e0fb565573e446b28 Author: Artem Bityutskiy Date: Wed May 16 15:49:16 2007 +0300 UBI: error path bugfix No need to unlock the lock, this will be done at out_unlock. Signed-off-by: Artem Bityutskiy commit f800f09bf44871f6c6e4d3e42a60946e1ea51b17 Author: Artem Bityutskiy Date: Sun May 6 16:45:43 2007 +0300 UBI: minor comma fix Use coma at the the last elements of structure initializer. Daniel Stone's explanation: Because it turns: - .attr = foo + .attr = foo, + .bar = baz into: + .bar = baz, i.e., far less likely to screw up a merge. Signed-off-by: Artem Bityutskiy commit 92ad8f37509a7d9d5dd6e0092211b092a7ca7fb1 Author: Artem Bityutskiy Date: Sun May 6 16:12:54 2007 +0300 UBI: use vmalloc for large buffers UBI allocates temporary buffers of PEB size, which may be 256KiB. Use vmalloc instead of kmalloc for such big temporary buffers. Signed-off-by: Artem Bityutskiy commit 79b510c0f21174f4bd055d1aab156e548ae3a5f2 Author: Artem Bityutskiy Date: Sat May 5 17:36:17 2007 +0300 UBI: add few more comments Add few comments above ubi_scan_add_used() to explain why it is so complex. Requested by Satyam Sharma . Signed-off-by: Artem Bityutskiy commit 941dfb07ed91451b1c58626a0d258dfdf468b593 Author: Artem Bityutskiy Date: Sat May 5 16:33:13 2007 +0300 UBI: set correct gluebi device size In case of static volumes, make emulated MTD device size to be equivalent to data size, rather then volume size. Reported-by: John Smith Signed-off-by: Artem Bityutskiy commit 4ab60a0d7c92cab16f7e470f80ea039a0b174bce Author: Artem Bityutskiy Date: Sat May 5 14:59:23 2007 +0300 UBI: do not let to read too much In case of static volumes it is prohibited to read more data then available. Signed-off-by: Artem Bityutskiy commit 78d87c95b89ccf86c142494beada3082810ed368 Author: Artem Bityutskiy Date: Sat May 5 11:24:02 2007 +0300 UBI: fix error path in create_vtbl() There were several bugs in volume table creation error path. Thanks to Satyam Sharma and Florin Malita for finding and analysing them: http://lkml.org/lkml/2007/5/3/274 This patch makes ubi_scan_add_to_list() static and renames it to add_to_list(), just because it is not needed outside scan.c anymore. Signed-off-by: Artem Bityutskiy commit c4e90ec0134d7bedebbe3fe58ed5d431293886d4 Author: Florin Malita Date: Thu May 3 11:49:57 2007 -0400 UBI: fix dereference after kfree Coverity (CID 1614) spotted new_seb being dereferenced after kfree() in crea