]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - android-sdk/kernel-video.git/log
android-sdk/kernel-video.git
13 years agoLinux 2.6.36-rc3 v2.6.36-rc3
Linus Torvalds [Sun, 29 Aug 2010 15:36:04 +0000 (08:36 -0700)]
Linux 2.6.36-rc3

13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394...
Linus Torvalds [Sun, 29 Aug 2010 15:19:02 +0000 (08:19 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
  firewire: ohci: work around VIA and NEC PHY packet reception bug
  firewire: core: do not use del_timer_sync() in interrupt context
  firewire: net: fix unicast reception RCODE in failure paths
  firewire: sbp2: fix stall with "Unsolicited response"
  firewire: sbp2: fix memory leak in sbp2_cancel_orbs or at send error
  ieee1394: Adjust confusing if indentation

13 years agofirewire: ohci: work around VIA and NEC PHY packet reception bug
Stefan Richter [Sat, 28 Aug 2010 12:21:26 +0000 (14:21 +0200)]
firewire: ohci: work around VIA and NEC PHY packet reception bug

VIA VT6306, VIA VT6308, and NEC OrangeLink controllers do not write
packet event codes for received PHY packets (or perhaps write
evt_no_status, hard to tell).  Work around it by overwriting the
packet's ACK by ack_complete, so that upper layers that listen to PHY
packet reception get to see these packets.

(Also tested:  TI TSB82AA2, TI TSB43AB22/A, TI XIO2213A, Agere FW643,
JMicron JMB381 --- these do not exhibit this bug.)

Clemens proposed a quirks flag for that, IOW whitelist known misbehaving
controllers for this workaround.  Though to me it seems harmless enough
to enable for all controllers.

The log_ar_at_event() debug log will continue to show the original
status from the DMA unit.

Reported-by: Clemens Ladisch <clemens@ladisch.de> (VT6308)
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
13 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Sat, 28 Aug 2010 22:42:44 +0000 (15:42 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
  net/ipv4: Eliminate kstrdup memory leak
  net/caif/cfrfml.c: use asm/unaligned.h
  ax25: missplaced sock_put(sk)
  qlge: reset the chip before freeing the buffers
  l2tp: test for ethernet header in l2tp_eth_dev_recv()
  tcp: select(writefds) don't hang up when a peer close connection
  tcp: fix three tcp sysctls tuning
  tcp: Combat per-cpu skew in orphan tests.
  pxa168_eth: silence gcc warnings
  pxa168_eth: update call to phy_mii_ioctl()
  pxa168_eth: fix error handling in prope
  pxa168_eth: remove unneeded null check
  phylib: Fix race between returning phydev and calling adjust_link
  caif-driver: add HAS_DMA dependency
  3c59x: Fix deadlock between boomerang_interrupt and boomerang_start_tx
  qlcnic: fix poll implementation
  netxen: fix poll implementation
  bridge: netfilter: fix a memory leak

13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/vapier...
Linus Torvalds [Sat, 28 Aug 2010 21:24:49 +0000 (14:24 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/vapier/blackfin

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/vapier/blackfin:
  Blackfin: bf52x/bf54x boards: drop unused nand page size
  Blackfin: punt duplicate SPORT MMR defines

13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
Linus Torvalds [Sat, 28 Aug 2010 21:24:34 +0000 (14:24 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: pcm: add more format names
  sound: oss: fix uninitialized spinlock
  ALSA: asihpi - Return hw error directly from oustream_write.
  ASoC: soc-core: fix debugfs_pop_time file permissions
  ALSA: hda - Add Sony VAIO quirk for ALC269

13 years agoMerge branch 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sat, 28 Aug 2010 21:12:05 +0000 (14:12 -0700)]
Merge branch 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung

* 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung:
  ARM: S5PV310: Fix on Secondary CPU startup
  ARM: S5PV310: Bug fix on uclk1 and sclk_pwm
  ARM: S5PV310: Fix missed uart clocks
  ARM: S5PV310: Should be clk_sclk_apll not clk_mout_apll
  ARM: S5PV310: Fix on PLL setting for S5PV310
  ARM: S5PV310: Add CMU block for S5PV310 Clock
  ARM: S5PV310: Fix on typo irqs.h of S5PV310
  ARM: S5PV310: Fix on default ZRELADDR of ARCH_S5PV310
  ARM: S5PV310: Fix on GPIO base addresses
  ARM: SAMSUNG: Fix on build warning regarding VMALLOC_END type
  ARM: S5P: VMALLOC_END should be unsigned long

13 years agoMerge branch 'for-linus' of git://git.infradead.org/users/eparis/notify
Linus Torvalds [Sat, 28 Aug 2010 21:11:04 +0000 (14:11 -0700)]
Merge branch 'for-linus' of git://git.infradead.org/users/eparis/notify

* 'for-linus' of git://git.infradead.org/users/eparis/notify:
  fsnotify: drop two useless bools in the fnsotify main loop
  fsnotify: fix list walk order
  fanotify: Return EPERM when a process is not privileged
  fanotify: resize pid and reorder structure
  fanotify: drop duplicate pr_debug statement
  fanotify: flush outstanding perm requests on group destroy
  fsnotify: fix ignored mask handling between inode and vfsmount marks
  fanotify: add MAINTAINERS entry
  fsnotify: reset used_inode and used_vfsmount on each pass
  fanotify: do not dereference inode_mark when it is unset

13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs...
Linus Torvalds [Sat, 28 Aug 2010 21:10:43 +0000 (14:10 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6:
  eCryptfs: Fix encrypted file name lookup regression
  ecryptfs: properly mark init functions
  fs/ecryptfs: Return -ENOMEM on memory allocation failure

13 years agoMerge branch 'for-linus' of git://android.git.kernel.org/kernel/tegra
Linus Torvalds [Sat, 28 Aug 2010 21:09:16 +0000 (14:09 -0700)]
Merge branch 'for-linus' of git://android.git.kernel.org/kernel/tegra

* 'for-linus' of git://android.git.kernel.org/kernel/tegra:
  arm: tegra: VMALLOC_END should be unsigned long
  arm: tegra: fix compilation of board-harmony.c

13 years agoMerge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied...
Linus Torvalds [Sat, 28 Aug 2010 21:08:38 +0000 (14:08 -0700)]
Merge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6

* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
  vgaarb: Wrap vga_(get|put) in CONFIG_VGA_ARB
  drm/radeon/kms: add missing scratch update in dp_detect
  drm/modes: Fix CVT-R modeline generation
  drm: fix regression in drm locking since BKL removal.
  drm/radeon/kms: remove stray radeon_i2c_destroy
  drm: mm: fix range restricted allocations
  drm/nouveau: drop drm_global_mutex before sleeping in submission path
  drm: export drm_global_mutex for drivers to use
  drm/nv20: Don't use pushbuf calls on the original nv20.
  drm/nouveau: Fix TMDS on some DCB1.5 boards.
  drm/nouveau: Fix backlight control on PPC machines with an internal TMDS panel.
  drm/nv30: Apply modesetting to the correct slave encoder
  drm/nouveau: Use a helper function to match PCI device/subsystem IDs.
  drm/nv50: add dcb type 14 to enum to prevent compiler complaint

13 years agoMerge branch 'lguest' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux...
Linus Torvalds [Sat, 28 Aug 2010 21:08:10 +0000 (14:08 -0700)]
Merge branch 'lguest' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus

* 'lguest' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus:
  lguest: Odd Fixes
  lguest: clean up warnings in demonstration launcher.

13 years agoMerge branch 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sat, 28 Aug 2010 21:07:38 +0000 (14:07 -0700)]
Merge branch 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6

* 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6:
  OMAP3: PM: ensure IO wakeups are properly disabled
  omap: Fix omap_4430sdp_defconfig for make oldconfig
  omap: Use CONFIG_SMP for test_for_ipi and test_for_ltirq
  omap: Fix sev instruction usage for multi-omap
  OMAP3: Fix a cpu type check problem
  omap3: id: fix 3630 rev detection

13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph...
Linus Torvalds [Sat, 28 Aug 2010 21:07:20 +0000 (14:07 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
  ceph: fix get_ticket_handler() error handling
  ceph: don't BUG on ENOMEM during mds reconnect
  ceph: ceph_mdsc_build_path() returns an ERR_PTR
  ceph: Fix warnings
  ceph: ceph_get_inode() returns an ERR_PTR
  ceph: initialize fields on new dentry_infos
  ceph: maintain i_head_snapc when any caps are dirty, not just for data
  ceph: fix osd request lru adjustment when sending request
  ceph: don't improperly set dir complete when holding EXCL cap
  mm: exporting account_page_dirty
  ceph: direct requests in snapped namespace based on nonsnap parent
  ceph: queue cap snap writeback for realm children on snap update
  ceph: include dirty xattrs state in snapped caps
  ceph: fix xattr cap writeback
  ceph: fix multiple mds session shutdown

13 years agoMerge branch 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspe...
Linus Torvalds [Sat, 28 Aug 2010 21:06:19 +0000 (14:06 -0700)]
Merge branch 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6

* 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6:
  PM QoS: Fix inline documentation.
  PM QoS: Fix kzalloc() parameters swapped in pm_qos_power_open()

13 years agoMerge branch 'for-2.6.36' of git://linux-nfs.org/~bfields/linux
Linus Torvalds [Sat, 28 Aug 2010 21:05:55 +0000 (14:05 -0700)]
Merge branch 'for-2.6.36' of git://linux-nfs.org/~bfields/linux

* 'for-2.6.36' of git://linux-nfs.org/~bfields/linux:
  nfsd: fix NULL dereference in nfsd_statfs()
  nfsd4: fix downgrade/lock logic
  nfsd4: typo fix in find_any_file
  nfsd4: bad BUG() in preprocess_stateid_op

13 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6
Linus Torvalds [Sat, 28 Aug 2010 21:05:15 +0000 (14:05 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
  Cannot allocate memory error on mount
  [CIFS] Eliminate unused variable warning

13 years agoAlpha: Fix a missing comma in sys_osf_statfs()
David Howells [Thu, 26 Aug 2010 16:44:35 +0000 (17:44 +0100)]
Alpha: Fix a missing comma in sys_osf_statfs()

Fix a comma that got accidentally deleted from sys_osf_statfs() leading to the
following warning:

  arch/alpha/kernel/osf_sys.c: In function 'SYSC_osf_statfs':
  arch/alpha/kernel/osf_sys.c:255: error: syntax error before 'buffer'

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
13 years agoNOMMU: Stub out vm_get_page_prot() if there's no MMU
David Howells [Thu, 26 Aug 2010 15:00:34 +0000 (16:00 +0100)]
NOMMU: Stub out vm_get_page_prot() if there's no MMU

Stub out vm_get_page_prot() if there's no MMU.

This was added by commit 804af2cf6e7a ("[AGPGART] remove private page
protection map") and is used in commit c07fbfd17e61 ("fbmem: VM_IO set,
but not propagated") in the fbmem video driver, but the function doesn't
exist on NOMMU, resulting in an undefined symbol at link time.

Signed-off-by: David Howells <dhowells@redhat.com>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp
Linus Torvalds [Sat, 28 Aug 2010 20:55:54 +0000 (13:55 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp:
  amd64_edac: Do not report error overflow as a separate error
  MCE, AMD: Limit MCE decoding to current families for now

13 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Linus Torvalds [Sat, 28 Aug 2010 20:55:31 +0000 (13:55 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: pxa27x_keypad - remove input_free_device() in pxa27x_keypad_remove()
  Input: mousedev - fix regression of inverting axes
  Input: uinput - add devname alias to allow module on-demand load
  Input: hil_kbd - fix compile error
  USB: drop tty argument from usb_serial_handle_sysrq_char()
  Input: sysrq - drop tty argument form handle_sysrq()
  Input: sysrq - drop tty argument from sysrq ops handlers

13 years agoMerge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzi...
Linus Torvalds [Sat, 28 Aug 2010 20:54:55 +0000 (13:54 -0700)]
Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev

* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
  libata-sff: remove harmful BUG_ON from ata_bmdma_qc_issue
  sata_mv: fix broken DSM/TRIM support (v2)
  libata: be less of a drama queen on empty data commands
  [libata] sata_dwc_460ex: signdness bug
  ahci: add HFLAG_YES_FBS and apply it to 88SE9128
  libata: remove no longer needed pata_winbond driver
  pata_cmd64x: revert commit d62f5576

13 years agomm: fix hang on anon_vma->root->lock
Hugh Dickins [Thu, 26 Aug 2010 06:12:54 +0000 (23:12 -0700)]
mm: fix hang on anon_vma->root->lock

After several hours, kbuild tests hang with anon_vma_prepare() spinning on
a newly allocated anon_vma's lock - on a box with CONFIG_TREE_PREEMPT_RCU=y
(which makes this very much more likely, but it could happen without).

The ever-subtle page_lock_anon_vma() now needs a further twist: since
anon_vma_prepare() and anon_vma_fork() are liable to change the ->root
of a reused anon_vma structure at any moment, page_lock_anon_vma()
needs to check page_mapped() again before succeeding, otherwise
page_unlock_anon_vma() might address a different root->lock.

Signed-off-by: Hugh Dickins <hughd@google.com>
Reviewed-by: Rik van Riel <riel@redhat.com>
Cc: Christoph Lameter <cl@linux.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
13 years agoMerge branch 'fix/asoc' into for-linus
Takashi Iwai [Sat, 28 Aug 2010 19:44:15 +0000 (21:44 +0200)]
Merge branch 'fix/asoc' into for-linus

13 years agoMerge branch 'fix/hda' into for-linus
Takashi Iwai [Sat, 28 Aug 2010 19:44:12 +0000 (21:44 +0200)]
Merge branch 'fix/hda' into for-linus

13 years agoALSA: pcm: add more format names
Dan Carpenter [Fri, 27 Aug 2010 20:02:15 +0000 (22:02 +0200)]
ALSA: pcm: add more format names

There were some new formats added in commit 15c0cee6c809 "ALSA: pcm:
Define G723 3-bit and 5-bit formats".  That commit increased
SNDRV_PCM_FORMAT_LAST as well.  My concern is that there are a couple
places which do:

        for (i = 0; i < SNDRV_PCM_FORMAT_LAST; i++) {
                if (dummy->pcm_hw.formats & (1ULL << i))
                        snd_iprintf(buffer, " %s", snd_pcm_format_name(i));
        }

I haven't tested these but it looks like if "i" were equal to
SNDRV_PCM_FORMAT_G723_24 or higher then we might read past the end of
the array.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agosound: oss: fix uninitialized spinlock
Akinobu Mita [Sat, 28 Aug 2010 04:25:33 +0000 (13:25 +0900)]
sound: oss: fix uninitialized spinlock

The spinlock lock in sound_timer.c is used without initialization.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agoALSA: asihpi - Return hw error directly from oustream_write.
Eliot Blennerhassett [Sat, 28 Aug 2010 07:52:24 +0000 (19:52 +1200)]
ALSA: asihpi - Return hw error directly from oustream_write.

If hw error is ignored, status is updated with invalid info.

Signed-off-by: Eliot Blennerhassett <eblennerhassett@audioscience.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agonet/ipv4: Eliminate kstrdup memory leak
Julia Lawall [Sat, 28 Aug 2010 02:31:56 +0000 (19:31 -0700)]
net/ipv4: Eliminate kstrdup memory leak

The string clone is only used as a temporary copy of the argument val
within the while loop, and so it should be freed before leaving the
function.  The call to strsep, however, modifies clone, so a pointer to the
front of the string is kept in saved_clone, to make it possible to free it.

The sematic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r exists@
local idexpression x;
expression E;
identifier l;
statement S;
@@

*x= \(kasprintf\|kstrdup\)(...);
...
if (x == NULL) S
... when != kfree(x)
    when != E = x
if (...) {
  <... when != kfree(x)
* goto l;
  ...>
* return ...;
}
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agofsnotify: drop two useless bools in the fnsotify main loop
Eric Paris [Sat, 28 Aug 2010 01:42:11 +0000 (21:42 -0400)]
fsnotify: drop two useless bools in the fnsotify main loop

The fsnotify main loop has 2 bools which indicated if we processed the
inode or vfsmount mark in that particular pass through the loop.  These
bool can we replaced with the inode_group and vfsmount_group variables
and actually make the code a little easier to understand.

Signed-off-by: Eric Paris <eparis@redhat.com>
13 years agofsnotify: fix list walk order
Eric Paris [Sat, 28 Aug 2010 01:24:24 +0000 (21:24 -0400)]
fsnotify: fix list walk order

Marks were stored on the inode and vfsmonut mark list in order from
highest memory address to lowest memory address.  The code to walk those
lists thought they were in order from lowest to highest with
unpredictable results when trying to match up marks from each.  It was
possible that extra events would be sent to userspace when inode
marks ignoring events wouldn't get matched with the vfsmount marks.

This problem only affected fanotify when using both vfsmount and inode
marks simultaneously.

Signed-off-by: Eric Paris <eparis@redhat.com>
13 years agofanotify: Return EPERM when a process is not privileged
Andreas Gruenbacher [Tue, 24 Aug 2010 10:58:54 +0000 (12:58 +0200)]
fanotify: Return EPERM when a process is not privileged

The appropriate error code when privileged operations are denied is
EPERM, not EACCES.

Signed-off-by: Andreas Gruenbacher <agruen@suse.de>
Signed-off-by: Eric Paris <paris@paris.rdu.redhat.com>
13 years agofanotify: resize pid and reorder structure
Tvrtko Ursulin [Fri, 20 Aug 2010 09:02:15 +0000 (10:02 +0100)]
fanotify: resize pid and reorder structure

resize pid and reorder the fanotify_event_metadata so it is naturally
aligned and we can work towards dropping the packed attributed

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@sophos.com>
Cc: Andreas Dilger <adilger@dilger.ca>
Signed-off-by: Eric Paris <eparis@redhat.com>
13 years agoBlackfin: bf52x/bf54x boards: drop unused nand page size
Barry Song [Wed, 2 Jun 2010 04:22:11 +0000 (04:22 +0000)]
Blackfin: bf52x/bf54x boards: drop unused nand page size

Now that the driver for the Blackfin on-chip NFC no longer uses/respects
the page_size from the platform resources (figures out the needs on the
fly), drop it from the platform resources.  This fixes some build errors
since the defines no longer exists.

Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoBlackfin: punt duplicate SPORT MMR defines
Mike Frysinger [Tue, 17 Nov 2009 15:40:30 +0000 (15:40 +0000)]
Blackfin: punt duplicate SPORT MMR defines

The common bfin_sport.h header now has unified definitions of these, so
stop polluting the global namespace.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
13 years agoASoC: soc-core: fix debugfs_pop_time file permissions
Axel Lin [Fri, 27 Aug 2010 02:34:27 +0000 (10:34 +0800)]
ASoC: soc-core: fix debugfs_pop_time file permissions

I think this is a typo, debugfs_pop_time should not be executable.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Liam Girdwood <lrg@slimloogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
13 years agoeCryptfs: Fix encrypted file name lookup regression
Tyler Hicks [Wed, 25 Aug 2010 15:26:37 +0000 (10:26 -0500)]
eCryptfs: Fix encrypted file name lookup regression

Fixes a regression caused by 21edad32205e97dc7ccb81a85234c77e760364c8

When file name encryption was enabled, ecryptfs_lookup() failed to use
the encrypted and encoded version of the upper, plaintext, file name
when performing a lookup in the lower file system. This made it
impossible to lookup existing encrypted file names and any newly created
files would have plaintext file names in the lower file system.

https://bugs.launchpad.net/ecryptfs/+bug/623087

Signed-off-by: Tyler Hicks <tyhicks@linux.vnet.ibm.com>
13 years agoecryptfs: properly mark init functions
Jerome Marchand [Tue, 17 Aug 2010 15:24:05 +0000 (17:24 +0200)]
ecryptfs: properly mark init functions

Some ecryptfs init functions are not prefixed by __init and thus not
freed after initialization. This patch saved about 1kB in ecryptfs
module.

Signed-off-by: Jerome Marchand <jmarchan@redhat.com>
Signed-off-by: Tyler Hicks <tyhicks@linux.vnet.ibm.com>
13 years agofs/ecryptfs: Return -ENOMEM on memory allocation failure
Julia Lawall [Wed, 11 Aug 2010 10:11:41 +0000 (12:11 +0200)]
fs/ecryptfs: Return -ENOMEM on memory allocation failure

In this code, 0 is returned on memory allocation failure, even though other
failures return -ENOMEM or other similar values.

A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression ret;
expression x,e1,e2,e3;
@@

ret = 0
... when != ret = e1
*x = \(kmalloc\|kcalloc\|kzalloc\)(...)
... when != ret = e2
if (x == NULL) { ... when != ret = e3
  return ret;
}
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Tyler Hicks <tyhicks@linux.vnet.ibm.com>
13 years agoARM: S5PV310: Fix on Secondary CPU startup
Changhwan Youn [Fri, 27 Aug 2010 08:57:44 +0000 (17:57 +0900)]
ARM: S5PV310: Fix on Secondary CPU startup

Following occurs on boot message without this patch.
    CPU1: processor failed to boot
    Brought up 1 CPUs
    SMP: Total of 1 processors activated...

This patch adds SYSRAM mapping for fixing Secondary CPU startup.
    CPU1: Booted secondary processor
    Brought up 2 CPUs
    SMP: Total of 2 processors activated...

Signed-off-by: Changhwan Youn <chaos.youn@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Bug fix on uclk1 and sclk_pwm
Jongpill Lee [Fri, 27 Aug 2010 08:53:26 +0000 (17:53 +0900)]
ARM: S5PV310: Bug fix on uclk1 and sclk_pwm

This patch fixes on enable and ctrlbit of uclk1 and sclk_pwm.

Signed-off-by: Jongpill Lee <boyko.lee@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Fix missed uart clocks
Jongpill Lee [Fri, 27 Aug 2010 07:50:47 +0000 (16:50 +0900)]
ARM: S5PV310: Fix missed uart clocks

This patch adds missed uart clocks for S5PV310/S5PC210.

Signed-off-by: Jongpill Lee <boyko.lee@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Should be clk_sclk_apll not clk_mout_apll
Jongpill Lee [Wed, 18 Aug 2010 13:20:31 +0000 (22:20 +0900)]
ARM: S5PV310: Should be clk_sclk_apll not clk_mout_apll

This patch adds clk_sclk_apll so that fixes on clk_mout_apll.

Signed-off-by: Jongpill Lee <boyko.lee@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Fix on PLL setting for S5PV310
Jongpill Lee [Wed, 18 Aug 2010 13:13:49 +0000 (22:13 +0900)]
ARM: S5PV310: Fix on PLL setting for S5PV310

This patch fixes on PLL setting for S5PV310/S5PC210.

Signed-off-by: Jongpill Lee <boyko.lee@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Add CMU block for S5PV310 Clock
Kukjin Kim [Wed, 18 Aug 2010 12:45:49 +0000 (21:45 +0900)]
ARM: S5PV310: Add CMU block for S5PV310 Clock

This patch adds CMU block for S5PV310/S5PC210 clock.
(CMU: Clock Management Unit)
Of course, changed current clock addresses for it together.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Fix on typo irqs.h of S5PV310
Kukjin Kim [Fri, 20 Aug 2010 10:09:31 +0000 (19:09 +0900)]
ARM: S5PV310: Fix on typo irqs.h of S5PV310

This patch fixes typo 'IRQ_WTD' in the irqs.h of S5PV310.
And minor update comments.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Fix on default ZRELADDR of ARCH_S5PV310
Kukjin Kim [Wed, 18 Aug 2010 12:03:24 +0000 (21:03 +0900)]
ARM: S5PV310: Fix on default ZRELADDR of ARCH_S5PV310

This patch adds default zreladdr of ARCH_S5PV310.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: S5PV310: Fix on GPIO base addresses
Kyungmin Park [Fri, 20 Aug 2010 11:41:31 +0000 (20:41 +0900)]
ARM: S5PV310: Fix on GPIO base addresses

The S5PV310/S5PC210 has following three GPIO base addresses.

Part1 Base Address=0x11400000
Part2 Base Address=0x11000000
Part3 Base Address=0x03860000

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
[kgene.kim@samsung.com: minor edit of title]
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
13 years agoARM: SAMSUNG: Fix on build warning regarding VMALLOC_END type
Kukjin Kim [Sat, 21 Aug 2010 00:03:16 +0000 (09:03 +0900)]
ARM: SAMSUNG: Fix on build warning regarding VMALLOC_END type

Fix this warning:

arch/arm/mm/init.c: In function 'mem_init':
arch/arm/mm/init.c:644: warning: format '%08lx' expects type
'long unsigned int', but argument 12 has type 'unsigned int'

And removes the useless parens and white space.

Reported-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Cc: Ben Dooks <ben-linux@fluff.org>
13 years agonet/caif/cfrfml.c: use asm/unaligned.h
Jeff Mahoney [Thu, 26 Aug 2010 23:11:08 +0000 (16:11 -0700)]
net/caif/cfrfml.c: use asm/unaligned.h

caif does not build on ia64 starting with 2.6.32-rc1.  Using
asm/unaligned.h instead of linux/unaligned/le_byteshift.h fixes the issue.

include/linux/unaligned/le_byteshift.h:40:50: error: redefinition of 'get_unaligned_le16'
include/linux/unaligned/le_byteshift.h:45:50: error: redefinition of 'get_unaligned_le32'
include/linux/unaligned/le_byteshift.h:50:50: error: redefinition of 'get_unaligned_le64'
include/linux/unaligned/le_byteshift.h:55:51: error: redefinition of 'put_unaligned_le16'
include/linux/unaligned/le_byteshift.h:60:51: error: redefinition of 'put_unaligned_le32'
include/linux/unaligned/le_byteshift.h:65:51: error: redefinition of 'put_unaligned_le64'
include/linux/unaligned/le_struct.h:31:51: note: previous definition of 'put_unaligned_le64' was here

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agovgaarb: Wrap vga_(get|put) in CONFIG_VGA_ARB
Chris Wilson [Thu, 19 Aug 2010 20:29:43 +0000 (21:29 +0100)]
vgaarb: Wrap vga_(get|put) in CONFIG_VGA_ARB

Fix link failure without the vga arbitrator.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Dave Airlie <airlied@redhat.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
13 years agodrm/radeon/kms: add missing scratch update in dp_detect
Alex Deucher [Sat, 21 Aug 2010 15:09:14 +0000 (11:09 -0400)]
drm/radeon/kms: add missing scratch update in dp_detect

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
13 years agodrm/modes: Fix CVT-R modeline generation
Adam Jackson [Mon, 23 Aug 2010 14:19:14 +0000 (10:19 -0400)]
drm/modes: Fix CVT-R modeline generation

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=16651

Signed-off-by: Adam Jackson <ajax@redhat.com>
Tested-by: Adam Serbinski <adam@serbinksi.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
13 years agodrm: fix regression in drm locking since BKL removal.
Arnd Bergmann [Thu, 26 Aug 2010 22:55:28 +0000 (08:55 +1000)]
drm: fix regression in drm locking since BKL removal.

This locking path needs proper auditing but probably too late for changes at this point for 2.6.36, so lets go with the quick fix, which is to drop the lock around schedule.

Reported-by: Andreas Schwab <schwab@linux-m68k.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
13 years agodrm/radeon/kms: remove stray radeon_i2c_destroy
Alex Deucher [Thu, 26 Aug 2010 16:22:04 +0000 (12:22 -0400)]
drm/radeon/kms: remove stray radeon_i2c_destroy

I missed this one in the i2c unification patch.  This
is handled in the core radeon i2c code now.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
13 years agodrm: mm: fix range restricted allocations
Daniel Vetter [Thu, 26 Aug 2010 19:44:17 +0000 (21:44 +0200)]
drm: mm: fix range restricted allocations

With the code cleanup in

7a6b2896f261894dde287d3faefa4b432cddca53 is the first bad commit
commit 7a6b2896f261894dde287d3faefa4b432cddca53
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Fri Jul 2 15:02:15 2010 +0100

    drm_mm: extract check_free_mm_node

I've botched up the range-restriction checks. The result is usually
an X server dying with SIGBUS in libpixman (software fallback rendering).
Change the code to adjust the start and end for range restricted
allocations. IMHO this even makes the code a bit clearer.

Fixes regression bug: https://bugs.freedesktop.org/show_bug.cgi?id=29738

Reported-by-Tested-by: Till MAtthiesen <entropy@everymail.net>
Acked-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
13 years agolguest: Odd Fixes
Rusty Russell [Fri, 27 Aug 2010 14:39:51 +0000 (08:39 -0600)]
lguest: Odd Fixes

It's been in fix-mode-only for a while now.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
13 years agolguest: clean up warnings in demonstration launcher.
Rusty Russell [Fri, 27 Aug 2010 14:39:48 +0000 (08:39 -0600)]
lguest: clean up warnings in demonstration launcher.

These days the headers we use are in glibc.  If those are too old, you can
add the -I lines to get the kernel headers.

In file included from ../../include/linux/if_tun.h:19,
                 from lguest.c:33:
../../include/linux/types.h:13:2: warning: #warning "Attempt to use kernel headers from user space, see http://kernelnewbies.org/KernelHeaders"
lguest.c: In function ‘setup_tun_net’:
lguest.c:1456: warning: dereferencing pointer ‘sin’ does break strict-aliasing rules
lguest.c:1457: warning: dereferencing pointer ‘sin’ does break strict-aliasing rules
lguest.c:1450: note: initialized from here

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
13 years agoMerge remote branch 'nouveau/for-airlied' of /ssd/git/drm-nouveau-next into drm-fixes
Dave Airlie [Thu, 26 Aug 2010 23:09:46 +0000 (09:09 +1000)]
Merge remote branch 'nouveau/for-airlied' of /ssd/git/drm-nouveau-next into drm-fixes

* 'nouveau/for-airlied' of /ssd/git/drm-nouveau-next:
  drm/nouveau: drop drm_global_mutex before sleeping in submission path
  drm: export drm_global_mutex for drivers to use
  drm/nv20: Don't use pushbuf calls on the original nv20.
  drm/nouveau: Fix TMDS on some DCB1.5 boards.
  drm/nouveau: Fix backlight control on PPC machines with an internal TMDS panel.
  drm/nv30: Apply modesetting to the correct slave encoder
  drm/nouveau: Use a helper function to match PCI device/subsystem IDs.
  drm/nv50: add dcb type 14 to enum to prevent compiler complaint

13 years agodrm/nouveau: drop drm_global_mutex before sleeping in submission path
Ben Skeggs [Thu, 26 Aug 2010 05:02:32 +0000 (15:02 +1000)]
drm/nouveau: drop drm_global_mutex before sleeping in submission path

If we keep hold of the mutex here, the process which currently holds the
buffer object will never be able to release it, causing a deadlock.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agodrm: export drm_global_mutex for drivers to use
Ben Skeggs [Thu, 26 Aug 2010 04:58:57 +0000 (14:58 +1000)]
drm: export drm_global_mutex for drivers to use

Nouveau needs to be able to drop the mutex before sleeping to prevent a
deadlock from occuring.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agoax25: missplaced sock_put(sk)
Bernard Pidoux F6BVP [Thu, 26 Aug 2010 11:40:00 +0000 (11:40 +0000)]
ax25: missplaced sock_put(sk)

This patch moves a missplaced sock_put(sk) after
bh_unlock_sock(sk)
like in other parts of AX25 driver.

Signed-off-by: Bernard Pidoux <f6bvp@free.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agoqlge: reset the chip before freeing the buffers
Breno Leitao [Thu, 26 Aug 2010 08:27:58 +0000 (08:27 +0000)]
qlge: reset the chip before freeing the buffers

Qlge is freeing the buffers before stopping the card DMA, and
this can cause some severe error, as a EEH event on PPC.

This patch just stop the card and then free the resources.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agol2tp: test for ethernet header in l2tp_eth_dev_recv()
Eric Dumazet [Wed, 25 Aug 2010 23:44:35 +0000 (23:44 +0000)]
l2tp: test for ethernet header in l2tp_eth_dev_recv()

close https://bugzilla.kernel.org/show_bug.cgi?id=16529

Before calling dev_forward_skb(), we should make sure skb head contains
at least an ethernet header, even if length included in upper layer said
so. Use pskb_may_pull() to make sure this ethernet header is present in
skb head.

Reported-by: Thomas Heil <heil@terminal-consulting.de>
Reported-by: Ian Campbell <Ian.Campbell@eu.citrix.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agoPM QoS: Fix inline documentation.
Saravana Kannan [Thu, 26 Aug 2010 18:18:43 +0000 (20:18 +0200)]
PM QoS: Fix inline documentation.

Fix the pm_qos_add_request() kerneldoc comment that doesn't reflect
the behavior of the function after the last PM QoS update.

Signed-off-by: Saravana Kannan <skannan@codeaurora.org>
Acked-by: mark gross <markgross@thegnar.org>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
13 years agonfsd: fix NULL dereference in nfsd_statfs()
Takashi Iwai [Fri, 13 Aug 2010 13:53:49 +0000 (15:53 +0200)]
nfsd: fix NULL dereference in nfsd_statfs()

The commit ebabe9a9001af0af56c0c2780ca1576246e7a74b
    pass a struct path to vfs_statfs
introduced the struct path initialization, and this seems to trigger
an Oops on my machine.

fh_dentry field may be NULL and set later in fh_verify(), thus the
initialization of path must be after fh_verify().

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Minchan Kim <minchan.kim@gmail.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
13 years agoMerge commit 'v2.6.36-rc1' into HEAD
J. Bruce Fields [Thu, 26 Aug 2010 17:22:27 +0000 (13:22 -0400)]
Merge commit 'v2.6.36-rc1' into HEAD

13 years agonfsd4: fix downgrade/lock logic
J. Bruce Fields [Fri, 20 Aug 2010 22:09:31 +0000 (18:09 -0400)]
nfsd4: fix downgrade/lock logic

If we already had a RW open for a file, and get a readonly open, we were
piggybacking on the existing RW open.  That's inconsistent with the
downgrade logic which blows away the RW open assuming you'll still have
a readonly open.

Also, make sure there is a readonly or writeonly open available for
locking, again to prevent bad behavior in downgrade cases when any RW
open may be lost.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
13 years agonfsd4: typo fix in find_any_file
J. Bruce Fields [Fri, 20 Aug 2010 22:06:26 +0000 (18:06 -0400)]
nfsd4: typo fix in find_any_file

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
13 years agonfsd4: bad BUG() in preprocess_stateid_op
J. Bruce Fields [Tue, 17 Aug 2010 22:46:33 +0000 (18:46 -0400)]
nfsd4: bad BUG() in preprocess_stateid_op

It's OK for this function to return without setting filp--we do it in
the special-stateid case.

And there's a legitimate case where we can hit this, since we do permit
reads on write-only stateid's.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
13 years agoCannot allocate memory error on mount
Suresh Jayaraman [Thu, 26 Aug 2010 09:16:09 +0000 (14:46 +0530)]
Cannot allocate memory error on mount

On 08/26/2010 01:56 AM, joe hefner wrote:
> On a recent Fedora (13), I am seeing a mount failure message that I can not explain. I have a Windows Server 2003ýa with a share set up for access only for a specific username (say userfoo). If I try to mount it from Linux,ýusing userfoo and the correct password all is well. If I try with a bad password or with some other username (userbar), it fails with "Permission denied" as expected. If I try to mount as username = administrator, and give the correct administrator password, I would also expect "Permission denied", but I see "Cannot allocate memory" instead.

> ýfs/cifs/netmisc.c: Mapping smb error code 5 to POSIX err -13
> ýfs/cifs/cifssmb.c: Send error in QPathInfo = -13
> ýCIFS VFS: cifs_read_super: get root inode failed

Looks like the commit 0b8f18e3 assumed that cifs_get_inode_info() and
friends fail only due to memory allocation error when the inode is NULL
which is not the case if CIFSSMBQPathInfo() fails and returns an error.
Fix this by propagating the actual error code back.

Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Suresh Jayaraman <sjayaraman@suse.de>
Signed-off-by: Steve French <sfrench@us.ibm.com>
13 years agoceph: fix get_ticket_handler() error handling
Dan Carpenter [Thu, 26 Aug 2010 09:12:38 +0000 (11:12 +0200)]
ceph: fix get_ticket_handler() error handling

get_ticket_handler() returns a valid pointer or it returns
ERR_PTR(-ENOMEM) if kzalloc() fails.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph: don't BUG on ENOMEM during mds reconnect
Sage Weil [Thu, 26 Aug 2010 16:26:37 +0000 (09:26 -0700)]
ceph: don't BUG on ENOMEM during mds reconnect

We are in a position to return an error; do that instead.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph: ceph_mdsc_build_path() returns an ERR_PTR
Dan Carpenter [Thu, 26 Aug 2010 09:07:24 +0000 (11:07 +0200)]
ceph: ceph_mdsc_build_path() returns an ERR_PTR

ceph_mdsc_build_path() returns an ERR_PTR but this code is set up to
handle NULL returns.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoamd64_edac: Do not report error overflow as a separate error
Borislav Petkov [Tue, 24 Aug 2010 16:21:42 +0000 (18:21 +0200)]
amd64_edac: Do not report error overflow as a separate error

When the Overflow MCi_STATUS bit is set, EDAC reports the lost error
with a "no information available" message which often puzzles users
parsing the dmesg. This doesn't make much sense since this error has
been lost anyway so no need for reporting it separately. Thus, report
the overflow bit setting in the MCE dump instead. While at it, remove
reporting of MiscV and ErrorEnable (en) which are superfluous.

Now it looks like this:

[ 1501.650024] MC4_STATUS: Corrected error, other errors lost: yes, CPU context corrupt: no, CECC Error
[ 1501.666887] Northbridge Error, node 2

Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
13 years agoALSA: hda - Add Sony VAIO quirk for ALC269
David Henningsson [Mon, 23 Aug 2010 06:14:35 +0000 (08:14 +0200)]
ALSA: hda - Add Sony VAIO quirk for ALC269

The attached patch enables playback on a Sony VAIO machine.

BugLink: http://launchpad.net/bugs/618271
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
13 years agotcp: select(writefds) don't hang up when a peer close connection
KOSAKI Motohiro [Tue, 24 Aug 2010 16:05:48 +0000 (16:05 +0000)]
tcp: select(writefds) don't hang up when a peer close connection

This issue come from ruby language community. Below test program
hang up when only run on Linux.

% uname -mrsv
Linux 2.6.26-2-486 #1 Sat Dec 26 08:37:39 UTC 2009 i686
% ruby -rsocket -ve '
BasicSocket.do_not_reverse_lookup = true
serv = TCPServer.open("127.0.0.1", 0)
s1 = TCPSocket.open("127.0.0.1", serv.addr[1])
s2 = serv.accept
s2.close
s1.write("a") rescue p $!
s1.write("a") rescue p $!
Thread.new {
  s1.write("a")
}.join'
ruby 1.9.3dev (2010-07-06 trunk 28554) [i686-linux]
#<Errno::EPIPE: Broken pipe>
[Hang Here]

FreeBSD, Solaris, Mac doesn't. because Ruby's write() method call
select() internally. and tcp_poll has a bug.

SUS defined 'ready for writing' of select() as following.

|  A descriptor shall be considered ready for writing when a call to an output
|  function with O_NONBLOCK clear would not block, whether or not the function
|  would transfer data successfully.

That said, EPIPE situation is clearly one of 'ready for writing'.

We don't have read-side issue because tcp_poll() already has read side
shutdown care.

|        if (sk->sk_shutdown & RCV_SHUTDOWN)
|                mask |= POLLIN | POLLRDNORM | POLLRDHUP;

So, Let's insert same logic in write side.

- reference url
  http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/31065
  http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/31068

Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agotcp: fix three tcp sysctls tuning
Eric Dumazet [Thu, 26 Aug 2010 06:02:17 +0000 (23:02 -0700)]
tcp: fix three tcp sysctls tuning

As discovered by Anton Blanchard, current code to autotune
tcp_death_row.sysctl_max_tw_buckets, sysctl_tcp_max_orphans and
sysctl_max_syn_backlog makes little sense.

The bigger a page is, the less tcp_max_orphans is : 4096 on a 512GB
machine in Anton's case.

(tcp_hashinfo.bhash_size * sizeof(struct inet_bind_hashbucket))
is much bigger if spinlock debugging is on. Its wrong to select bigger
limits in this case (where kernel structures are also bigger)

bhash_size max is 65536, and we get this value even for small machines.

A better ground is to use size of ehash table, this also makes code
shorter and more obvious.

Based on a patch from Anton, and another from David.

Reported-and-tested-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
13 years agodrm/nv20: Don't use pushbuf calls on the original nv20.
Francisco Jerez [Wed, 25 Aug 2010 10:54:53 +0000 (12:54 +0200)]
drm/nv20: Don't use pushbuf calls on the original nv20.

The "return" command is buggy on the original nv20, it jumps back to
the caller address as expected, but it doesn't clear the subroutine
active bit making the subsequent pushbuf calls fail with a "stack"
overflow.

Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agodrm/nouveau: Fix TMDS on some DCB1.5 boards.
Francisco Jerez [Tue, 24 Aug 2010 21:02:02 +0000 (23:02 +0200)]
drm/nouveau: Fix TMDS on some DCB1.5 boards.

The TMDS output of an nv11 was being detected as LVDS, because it uses
DCB type 2 for TMDS instead of type 4.

Reported-by: Bertrand VIEILLE <Vieille.Bertrand@free.fr>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agodrm/nouveau: Fix backlight control on PPC machines with an internal TMDS panel.
Francisco Jerez [Fri, 20 Aug 2010 12:19:45 +0000 (14:19 +0200)]
drm/nouveau: Fix backlight control on PPC machines with an internal TMDS panel.

This commit fixes fdo bug 29685.

Reported-by: Vlado Plaga <rechner@vlado-do.de>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agodrm/nv30: Apply modesetting to the correct slave encoder
Patrice Mandin [Wed, 18 Aug 2010 14:07:34 +0000 (16:07 +0200)]
drm/nv30: Apply modesetting to the correct slave encoder

Signed-off-by: Patrice Mandin <patmandin@gmail.com>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agodrm/nouveau: Use a helper function to match PCI device/subsystem IDs.
Francisco Jerez [Sun, 15 Aug 2010 12:31:31 +0000 (14:31 +0200)]
drm/nouveau: Use a helper function to match PCI device/subsystem IDs.

Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agodrm/nv50: add dcb type 14 to enum to prevent compiler complaint
Ben Skeggs [Tue, 17 Aug 2010 04:34:00 +0000 (14:34 +1000)]
drm/nv50: add dcb type 14 to enum to prevent compiler complaint

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years ago[CIFS] Eliminate unused variable warning
Steve French [Thu, 26 Aug 2010 02:11:54 +0000 (02:11 +0000)]
[CIFS] Eliminate unused variable warning

CC: Shirish Pargaonkar <shirishp@us.ibm.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
13 years agolibata-sff: remove harmful BUG_ON from ata_bmdma_qc_issue
Mark Lord [Fri, 20 Aug 2010 14:13:16 +0000 (10:13 -0400)]
libata-sff: remove harmful BUG_ON from ata_bmdma_qc_issue

Remove harmful BUG_ON() from ata_bmdma_qc_issue(),
as it casts too wide of a net and breaks sata_mv.
It also crashes the kernel while doing the BUG_ON().

There's already a WARN_ON_ONCE() further down to catch
the case of POLLING for a BMDMA operation.

Signed-off-by: Mark Lord <mlord@pobox.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Cc: stable@kernel.org
13 years agosata_mv: fix broken DSM/TRIM support (v2)
Mark Lord [Fri, 20 Aug 2010 01:40:44 +0000 (21:40 -0400)]
sata_mv: fix broken DSM/TRIM support (v2)

Fix DSM/TRIM commands in sata_mv (v2).
These need to be issued using old-school "BM DMA",
rather than via the EDMA host queue.

Since the chips don't have proper BM DMA status,
we need to be more careful with setting the ATA_DMA_INTR bit,
since DSM/TRIM often has a long delay between "DMA complete"
and "command complete".

GEN_I chips don't have BM DMA, so no TRIM for them.

Signed-off-by: Mark Lord <mlord@pobox.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Cc: stable@kernel.org
13 years agolibata: be less of a drama queen on empty data commands
Tejun Heo [Mon, 23 Aug 2010 09:27:27 +0000 (11:27 +0200)]
libata: be less of a drama queen on empty data commands

ata_qc_issue() BUG_ON()s on data commands w/o data, which may be
submitted via SG_IO.  Be less of a drama queen and just trigger
WARN_ON_ONCE() and fail the command with AC_ERR_SYSTEM.

Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-by: Stefan Hübner <stefan.huebner@stud.tu-ilmenau.de>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
13 years ago[libata] sata_dwc_460ex: signdness bug
Dan Carpenter [Sat, 21 Aug 2010 08:43:25 +0000 (10:43 +0200)]
[libata] sata_dwc_460ex: signdness bug

dma_dwc_xfer_setup() returns an int and "dma_chan" needs to be signed
for the error handling to work.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
13 years agoahci: add HFLAG_YES_FBS and apply it to 88SE9128
Tejun Heo [Sat, 24 Jul 2010 14:53:48 +0000 (16:53 +0200)]
ahci: add HFLAG_YES_FBS and apply it to 88SE9128

88SE9128 can do FBS and sets it in HOST_CAP but forgets to set FBSCP
in PORT_CMD.  Implement AHCI_HFLAG_YES_FBS and apply it to 88SE9128.

Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
13 years agolibata: remove no longer needed pata_winbond driver
Bartlomiej Zolnierkiewicz [Wed, 25 Nov 2009 07:08:33 +0000 (07:08 +0000)]
libata: remove no longer needed pata_winbond driver

Winbond W83759A controller is fully supported by pata_legacy driver
so remove no longer needed pata_winbond driver.

Leave PATA_WINBOND_VLB config option for compatibility reasons
and teach pata_legacy to preserve the old behavior of pata_winbond
driver.

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
13 years agopata_cmd64x: revert commit d62f5576
Tejun Heo [Tue, 17 Aug 2010 12:13:42 +0000 (14:13 +0200)]
pata_cmd64x: revert commit d62f5576

Commit d62f5576 (pata_cmd64x: fix handling of address setup timings)
incorrectly called ata_timing_compute() on UDMA mode on 0 @UT leading
to devide by zero fault.  Revert it until better fix is available.
This is reported in bko#16607 by Milan Kocian who also root caused it.

  https://bugzilla.kernel.org/show_bug.cgi?id=16607

Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-and-root-caused-by: Milan Kocian <milan.kocian@wq.cz>
Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
13 years agoceph: Fix warnings
Alan Cox [Wed, 25 Aug 2010 12:26:32 +0000 (13:26 +0100)]
ceph: Fix warnings

Just scrubbing some warnings so I can see real problem ones in the build
noise. For 32bit we need to coax gcc politely into believing we really
honestly intend to the casts. Using (u64)(unsigned long) means we cast from
a pointer to a type of the right size and then extend it. This stops the
warning spew.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph: ceph_get_inode() returns an ERR_PTR
Dan Carpenter [Wed, 25 Aug 2010 07:11:35 +0000 (09:11 +0200)]
ceph: ceph_get_inode() returns an ERR_PTR

ceph_get_inode() returns an ERR_PTR and it doesn't return a NULL.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMerge branch 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 25 Aug 2010 17:50:07 +0000 (10:50 -0700)]
Merge branch 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  perf, x86, Pentium4: Clear the P4_CCCR_FORCE_OVF flag
  tracing/trace_stack: Fix stack trace on ppc64

13 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6
Linus Torvalds [Wed, 25 Aug 2010 16:57:59 +0000 (09:57 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
  Eliminate sparse warning - bad constant expression
  cifs: check for NULL session password
  missing changes during ntlmv2/ntlmssp auth and sign
  [CIFS] Fix ntlmv2 auth with ntlmssp
  cifs: correction of unicode header files
  cifs: fix NULL pointer dereference in cifs_find_smb_ses
  cifs: consolidate error handling in several functions
  cifs: clean up error handling in cifs_mknod

13 years agoMerge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelv...
Linus Torvalds [Wed, 25 Aug 2010 15:41:18 +0000 (08:41 -0700)]
Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging

* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging:
  MAINTAINERS: hwmon/coretemp: Change maintainers
  hwmon: (k8temp) Differentiate between AM2 and ASB1
  hwmon: (ads7871) Fix ads7871_probe error paths
  hwmon: (coretemp) Fix harmless build warning

13 years agoMerge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 25 Aug 2010 15:40:56 +0000 (08:40 -0700)]
Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86, tsc, sched: Recompute cyc2ns_offset's during resume from sleep states
  sched: Fix rq->clock synchronization when migrating tasks

13 years agoMerge branch 'upstream/core' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen
Linus Torvalds [Wed, 25 Aug 2010 15:40:31 +0000 (08:40 -0700)]
Merge branch 'upstream/core' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen

* 'upstream/core' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen:
  xen: handle events as edge-triggered
  xen: use percpu interrupts for IPIs and VIRQs

13 years agoMerge branch '2.6.36-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/dgc...
Linus Torvalds [Wed, 25 Aug 2010 15:39:07 +0000 (08:39 -0700)]
Merge branch '2.6.36-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/dgc/xfsdev

* '2.6.36-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/dgc/xfsdev:
  xfs: do not discard page cache data on EAGAIN
  xfs: don't do memory allocation under the CIL context lock
  xfs: Reduce log force overhead for delayed logging
  xfs: dummy transactions should not dirty VFS state
  xfs: ensure f_ffree returned by statfs() is non-negative
  xfs: handle negative wbc->nr_to_write during sync writeback
  writeback: write_cache_pages doesn't terminate at nr_to_write <= 0
  xfs: fix untrusted inode number lookup
  xfs: ensure we mark all inodes in a freed cluster XFS_ISTALE
  xfs: unlock items before allowing the CIL to commit