aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-03-25Fix permissions of drivers/power/avs/rockchip-io-domain.cRafael J. Wysocki1-0/+0
The permissions of this file were modified by commit (f447671b9e4f PM / AVS: rockchip-io: add io selectors and supplies for rk3399) by mistake, so fix them. Signed-off-by: Rafael J. Wysocki <[email protected]>
2016-03-25configfs: fix CONFIGFS_BIN_ATTR_[RW]O definitionsOctavian Purdila1-2/+2
The type should be struct configfs_bin_attribute and not struct configfs_attribute. Signed-off-by: Octavian Purdila <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
2016-03-25libceph: use KMEM_CACHE macroGeliang Tang1-8/+2
Use KMEM_CACHE() instead of kmem_cache_create() to simplify the code. Signed-off-by: Geliang Tang <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25ceph: use kmem_cache_zallocGeliang Tang2-2/+2
Use kmem_cache_zalloc() instead of kmem_cache_alloc() with flag GFP_ZERO. Signed-off-by: Geliang Tang <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25rbd: use KMEM_CACHE macroGeliang Tang1-8/+2
Use KMEM_CACHE() instead of kmem_cache_create() to simplify the code. Signed-off-by: Geliang Tang <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25ceph: use lookup request to revalidate dentryYan, Zheng2-0/+35
If dentry has no lease, ceph_d_revalidate() previously return 0. This causes VFS to invalidate the dentry and create a new dentry for later lookup. Invalidating a dentry also detach any underneath mount points. So mount point inside cephfs can disapear mystically (even the mount point is not modified by other hosts). The fix is using lookup request to revalidate dentry without lease. This can partly solve the mount points disapear issue (as long as the mount point is not modified by other hosts) Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: kill ceph_get_dentry_parent_inode()Yan, Zheng2-20/+5
use vfs helper dget_parent() instead Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: fix security xattr deadlockYan, Zheng8-11/+125
When security is enabled, security module can call filesystem's getxattr/setxattr callbacks during d_instantiate(). For cephfs, d_instantiate() is usually called by MDS' dispatch thread, while handling MDS reply. If the MDS reply does not include xattrs and corresponding caps, getxattr/setxattr need to send a new request to MDS and waits for the reply. This makes MDS' dispatch sleep, nobody handles later MDS replies. The fix is make sure lookup/atomic_open reply include xattrs and corresponding caps. So getxattr can be handled by cached xattrs. This requires some modification to both MDS and request message. (Client tells MDS what caps it wants; MDS encodes proper caps in the reply) Smack security module may call setxattr during d_instantiate(). Unlike getxattr, we can't force MDS to issue CEPH_CAP_XATTR_EXCL to us. So just make setxattr return error when called by MDS' dispatch thread. Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: don't request vxattrs from MDSYan, Zheng1-2/+4
It's uselese because MDS reply does not carry any vxattr. Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: fix mounting same fs multiple timesYan, Zheng1-18/+15
Now __ceph_open_session() only accepts closed client. An opened client will tigger BUG_ON(). Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: remove unnecessary NULL checkYan, Zheng1-2/+2
If page->mapping is NULL, releasepage() callback does not get called. Remove the unnecessary NULL check to make static code analysis tool happy Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: avoid updating directory inode's i_size accidentallyYan, Zheng1-0/+4
Directory inode's i_size is used by readdir cache. Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: fix race during filling readdir cacheYan, Zheng1-2/+7
Readdir cache uses page cache to save dentry pointers. When adding dentry pointers to middle of a page, we need to make sure the page already exists. Otherwise the beginning part of the page will be invalid pointers. Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25libceph: use sizeof_footer() moreIlya Dryomov1-16/+3
Don't open-code sizeof_footer() in read_partial_message() and ceph_msg_revoke(). Also, after switching to sizeof_footer(), it's now possible to use con_out_kvec_add() in prepare_write_message_footer(). Signed-off-by: Ilya Dryomov <[email protected]> Reviewed-by: Alex Elder <[email protected]>
2016-03-25ceph: kill ceph_empty_snapcIlya Dryomov4-34/+6
ceph_empty_snapc->num_snaps == 0 at all times. Passing such a snapc to ceph_osdc_alloc_request() (possibly through ceph_osdc_new_request()) is equivalent to passing NULL, as ceph_osdc_alloc_request() uses it only for sizing the request message. Further, in all four cases the subsequent ceph_osdc_build_request() is passed NULL for snapc, meaning that 0 is encoded for seq and num_snaps and making ceph_empty_snapc entirely useless. The two cases where it actually mattered were removed in commits 860560904962 ("ceph: avoid sending unnessesary FLUSHSNAP message") and 23078637e054 ("ceph: fix queuing inode to mdsdir's snaprealm"). Signed-off-by: Ilya Dryomov <[email protected]> Reviewed-by: Yan, Zheng <[email protected]>
2016-03-25ceph: fix a wrong comparisonAnton Protopopov1-1/+1
A negative value rc compared to the positive value ENOENT in the finish_read() function. Signed-off-by: Anton Protopopov <[email protected]> Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: replace CURRENT_TIME by current_fs_time()Deepa Dinamani4-6/+6
CURRENT_TIME macro is not appropriate for filesystems as it doesn't use the right granularity for filesystem timestamps. Use current_fs_time() instead. Signed-off-by: Deepa Dinamani <[email protected]> Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: scattered page writebackYan, Zheng1-109/+196
This patch makes ceph_writepages_start() try using single OSD request to write all dirty pages within a strip unit. When a nonconsecutive dirty page is found, ceph_writepages_start() tries starting a new write operation to existing OSD request. If it succeeds, it uses the new operation to writeback the dirty page. Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25libceph: add helper that duplicates last extent operationYan, Zheng2-0/+24
This helper duplicates last extent operation in OSD request, then adjusts the new extent operation's offset and length. The helper is for scatterd page writeback, which adds nonconsecutive dirty pages to single OSD request. Signed-off-by: Yan, Zheng <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: enable large, variable-sized OSD requestsIlya Dryomov3-19/+32
Turn r_ops into a flexible array member to enable large, consisting of up to 16 ops, OSD requests. The use case is scattered writeback in cephfs and, as far as the kernel client is concerned, 16 is just a made up number. r_ops had size 3 for copyup+hint+write, but copyup is really a special case - it can only happen once. ceph_osd_request_cache is therefore stuffed with num_ops=2 requests, anything bigger than that is allocated with kmalloc(). req_mempool is backed by ceph_osd_request_cache, which means either num_ops=1 or num_ops=2 for use_mempool=true - all existing users (ceph_writepages_start(), ceph_osdc_writepages()) are fine with that. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: osdc->req_mempool should be backed by a slab poolIlya Dryomov1-2/+2
ceph_osd_request_cache was introduced a long time ago. Also, osd_req is about to get a flexible array member, which ceph_osd_request_cache is going to be aware of. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: make r_request msg_size calculation clearerIlya Dryomov1-10/+11
Although msg_size is calculated correctly, the terms are grouped in a misleading way - snaps appears to not have room for a u32 length. Move calculation closer to its use and regroup terms. No functional change. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: move r_reply_op_{len,result} into struct ceph_osd_req_opYan, Zheng3-5/+6
This avoids defining large array of r_reply_op_{len,result} in in struct ceph_osd_request. Signed-off-by: Yan, Zheng <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: rename ceph_osd_req_op::payload_len to indata_lenIlya Dryomov2-7/+7
Follow userspace nomenclature on this - the next commit adds outdata_len. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25ceph: remove useless BUG_ONYan, Zheng1-2/+0
ceph_osdc_start_request() never return -EOLDSNAP Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: don't enable rbytes mount option by defaultYan, Zheng2-4/+3
When rbytes mount option is enabled, directory size is recursive size. Recursive size is not updated instantly. This can cause directory size to change between successive stat(1) Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25ceph: encode ctime in cap messageYan, Zheng1-4/+7
Signed-off-by: Yan, Zheng <[email protected]>
2016-03-25libceph: behave in mon_fault() if cur_mon < 0Ilya Dryomov1-14/+9
This can happen if __close_session() in ceph_monc_stop() races with a connection reset. We need to ignore such faults, otherwise it's likely we would take !hunting, call __schedule_delayed() and end up with delayed_work() executing on invalid memory, among other things. The (two!) con->private tests are useless, as nothing ever clears con->private. Nuke them. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: reschedule tick in mon_fault()Ilya Dryomov1-4/+4
Doing __schedule_delayed() in the hunting branch is pointless, as the tick will have already been scheduled by then. What we need to do instead is *reschedule* it in the !hunting branch, after reopen_session() changes hunt_mult, which affects the delay. This helps with spacing out connection attempts and avoiding things like two back-to-back attempts followed by a longer period of waiting around. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: introduce and switch to reopen_session()Ilya Dryomov1-17/+16
hunting is now set in __open_session() and cleared in finish_hunting(), instead of all around. The "session lost" message is printed not only on connection resets, but also on keepalive timeouts. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: monc hunt rate is 3s with backoff up to 30sIlya Dryomov3-9/+22
Unless we are in the process of setting up a client (i.e. connecting to the monitor cluster for the first time), apply a backoff: every time we want to reopen a session, increase our timeout by a multiple (currently 2); when we complete the connection, reduce that multipler by 50%. Mirrors ceph.git commit 794c86fd289bd62a35ed14368fa096c46736e9a2. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: monc ping rate is 10sIlya Dryomov3-9/+5
Split ping interval and ping timeout: ping interval is 10s; keepalive timeout is 30s. Make monc_ping_timeout a constant while at it - it's not actually exported as a mount option (and the rest of tick-related settings won't be either), so it's got no place in ceph_options. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: pick a different monitor when reconnectingIlya Dryomov1-28/+57
Don't try to reconnect to the same monitor when we fail to establish a session within a timeout or it's lost. For that, pick_new_mon() needs to see the old value of cur_mon, so don't clear it in __close_session() - all calls to __close_session() but one are followed by __open_session() anyway. __open_session() is only called when a new session needs to be established, so the "already open?" branch, which is now in the way, is simply dropped. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: revamp subs code, switch to SUBSCRIBE2 protocolIlya Dryomov8-95/+174
It is currently hard-coded in the mon_client that mdsmap and monmap subs are continuous, while osdmap sub is always "onetime". To better handle full clusters/pools in the osd_client, we need to be able to issue continuous osdmap subs. Revamp subs code to allow us to specify for each sub whether it should be continuous or not. Although not strictly required for the above, switch to SUBSCRIBE2 protocol while at it, eliminating the ambiguity between a request for "every map since X" and a request for "just the latest" when we don't have a map yet (i.e. have epoch 0). SUBSCRIBE2 feature bit is now required - it's been supported since pre-argonaut (2010). Move "got mdsmap" call to the end of ceph_mdsc_handle_map() - calling in before we validate the epoch and successfully install the new map can mess up mon_client sub state. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: decouple hunting and subs managementIlya Dryomov1-9/+22
Coupling hunting state with subscribe state is not a good idea. Clear hunting when we complete the authentication handshake. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25libceph: move debugfs initialization into __ceph_open_session()Ilya Dryomov2-51/+4
Our debugfs dir name is a concatenation of cluster fsid and client unique ID ("global_id"). It used to be the case that we learned global_id first, nowadays we always learn fsid first - the monmap is sent before any auth replies are. ceph_debugfs_client_init() call in ceph_monc_handle_map() is therefore never executed and can be removed. Its counterpart in handle_auth_reply() doesn't really belong there either: having to do monc->client and unlocking early to work around lockdep is a testament to that. Move it into __ceph_open_session(), where it can be called unconditionally. Signed-off-by: Ilya Dryomov <[email protected]>
2016-03-25Revert "ppdev: use new parport device model"Linus Torvalds1-20/+5
This reverts commit e7223f18603374d235d8bb0398532323e5f318b9. It causes problems when a ppdev tries to register before the parport driver has been registered with the device model. That will trigger the BUG_ON(!drv->bus->p); at drivers/base/driver.c:153. The call chain is kernel_init -> kernel_init_freeable -> do_one_initcall -> ppdev_init -> __parport_register_driver -> driver_register *BOOM* Reported-by: kernel test robot <[email protected]> Reported-by: Ross Zwisler <[email protected]> Reported-by: Petr Mladek <[email protected]> Cc: Sudip Mukherjee <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2016-03-25Merge tag 'firewire-update2' of ↵Linus Torvalds1-3/+5
git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394 Pull firewire leftover from Stefan Richter: "Occurrences of timeval were supposed to be eliminated last round, now remove a last forgotten one" * tag 'firewire-update2' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394: firewire: nosy: Replace timeval with timespec64
2016-03-25Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linuxLinus Torvalds15-98/+147
Pull drm fixes from Dave Airlie: "Just a couple of dma-buf related fixes and some amdgpu fixes, along with a regression fix for radeon off but default feature, but makes my 30" monitor happy again" * 'drm-next' of git://people.freedesktop.org/~airlied/linux: drm/radeon/mst: cleanup code indentation drm/radeon/mst: fix regression in lane/link handling. drm/amdgpu: add invalidate_page callback for userptrs drm/amdgpu: Revert "remove the userptr rmn->lock" drm/amdgpu: clean up path handling for powerplay drm/amd/powerplay: fix memory leak of tdp_table dma-buf/fence: fix fence_is_later v2 dma-buf: Update docs for SYNC ioctl drm: remove excess description dma-buf, drm, ion: Propagate error code from dma_buf_start_cpu_access() drm/atmel-hlcdc: use helper to get crtc state drm/atomic: use helper to get crtc state
2016-03-25net: macb: remove BUG_ON() and reset the queue to handle RX errorsCyrille Pitchen1-10/+49
This patch removes two BUG_ON() used to notify about RX queue corruptions on macb (not gem) hardware without actually handling the error. The new code skips corrupted frames but still processes faultless frames. Then it resets the RX queue before restarting the reception from a clean state. This patch is a rework of an older patch proposed by Neil Armstrong: http://patchwork.ozlabs.org/patch/371525/ Signed-off-by: Cyrille Pitchen <[email protected]> Acked-by: Neil Armstrong <[email protected]> Acked-by: Nicolas Ferre <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2016-03-25qlge: Update version to 1.00.00.35Manish Chopra1-1/+1
Just updating version as many fixes got accumulated over 1.00.00.34 Signed-off-by: Manish Chopra <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2016-03-25net: phy: bcm7xxx: Add entries for Broadcom BCM7346 and BCM7362Jaedon Shin2-0/+6
Add PHY entries for the Broadcom BCM7346 and BCM7362 chips, these are 40nm generation Ethernet PHY. Fixes: 815717d1473e ("net: phy: bcm7xxx: Remove wildcard entries") Signed-off-by: Jaedon Shin <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2016-03-25bpf: add missing map_flags to bpf_map_show_fdinfoDaniel Borkmann1-2/+4
Add map_flags attribute to bpf_map_show_fdinfo(), so that tools like tc can check for them when loading objects from a pinned entry, e.g. if user intent wrt allocation (BPF_F_NO_PREALLOC) is different to the pinned object, it can bail out. Follow-up to 6c9059817432 ("bpf: pre-allocate hash map elements"), so that tc can still support this with v4.6. Signed-off-by: Daniel Borkmann <[email protected]> Acked-by: Alexei Starovoitov <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2016-03-25netpoll: Fix extra refcount release in netpoll_cleanup()Bjorn Helgaas1-1/+2
netpoll_setup() does a dev_hold() on np->dev, the netpoll device. If it fails, it correctly does a dev_put() but leaves np->dev set. If we call netpoll_cleanup() after the failure, np->dev is still set so we do another dev_put(), which decrements the refcount an extra time. It's questionable to call netpoll_cleanup() after netpoll_setup() fails, but it can be difficult to find the problem, and we can easily avoid it in this case. The extra decrements can lead to hangs like this: unregister_netdevice: waiting for bond0 to become free. Usage count = -3 Set and clear np->dev at the points where we dev_hold() and dev_put() the device. Signed-off-by: Bjorn Helgaas <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2016-03-25drm/radeon: add a dpm quirk for sapphire Dual-X R7 370 2G D5Alex Deucher1-0/+1
bug: https://bugs.freedesktop.org/show_bug.cgi?id=94692 Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
2016-03-25drm/amd: Beef up ACP Kconfig menu textBorislav Petkov1-2/+6
The current "text" needs a user to use a crystal ball in order to find out what this ACP thing is. Use the text from a8fe58cec351 ("drm/amd: add ACP driver support") to make it a bit more understandable to the rest of the world. Signed-off-by: Borislav Petkov <[email protected]> Cc: Alex Deucher <[email protected]> Cc: Chunming Zhou <[email protected]> Cc: Jammy Zhou <[email protected]> Cc: Maruthi Bayyavarapu <[email protected]> Cc: Murali Krishna Vemuri <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-03-25perf/x86: Move events_sysfs_show() outside CPU_SUP_INTELHuang Rui1-3/+3
randconfig builds can sometimes disable CONFIG_CPU_SUP_INTEL while enabling the AMD power reporting PMU driver, resulting in this build failure: arch/x86/kernel/cpu/perf_event.h:663:31: error: 'events_sysfs_show' undeclared here (not in a function) To fix it, move events_sysfs_show() outside of #ifdef CONFIG_CPU_SUP_INTEL. Reported-by: Randy Dunlap <[email protected]> Reported-by: build test robot <[email protected]> Signed-off-by: Huang Rui <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: Fengguang Wu <[email protected]> Cc: Linus Torvalds <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Sherry Hurwitz <[email protected]> Cc: Stephen Rothwell <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Ingo Molnar <[email protected]>
2016-03-25Merge tag 'perf-urgent-for-mingo-20160324' of ↵Ingo Molnar2-1/+2
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent Pull perf/urgent fixes from Arnaldo Carvalho de Melo: - Fix detached tarball building due to missing 'perf bench memcpy' headers (Arnaldo Carvalho de Melo) - Fix tarpkg build test error output redirection (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <[email protected]> Signed-off-by: Ingo Molnar <[email protected]>
2016-03-24Merge tag 'asm-generic-4.6' of ↵Linus Torvalds13-29/+4
git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic Pull asm-generic updates from Arnd Bergmann: "There are only three patches this time, most other changes to files in include/asm-generic tend to go through the tree of whoever depends on the change. Two patches are cleanups for stuff that is no longer needed, the main change is to adapt the generic version of BUG_ON() for CONFIG_BUG=n to make it behave consistently with BUG(). This avoids undefined behavior along with a number of warnings about that undefined behavior in randconfig builds when we keep going on after hitting a BUG_ON()" * tag 'asm-generic-4.6' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic: asm-generic: remove old nonatomic-io wrapper files asm-generic: default BUG_ON(x) to if(x)BUG() asm-generic: page.h: Remove useless get_user_page and free_user_page
2016-03-25Merge branch 'drm-next-4.6' of git://people.freedesktop.org/~agd5f/linux ↵Dave Airlie4-58/+102
into drm-next some amd fixes * 'drm-next-4.6' of git://people.freedesktop.org/~agd5f/linux: drm/radeon/mst: cleanup code indentation drm/radeon/mst: fix regression in lane/link handling. drm/amdgpu: add invalidate_page callback for userptrs drm/amdgpu: Revert "remove the userptr rmn->lock" drm/amdgpu: clean up path handling for powerplay drm/amd/powerplay: fix memory leak of tdp_table