Commit Graph

328374 Commits

Author SHA1 Message Date
Dan Pasanen d004f32e58 defconfig: disable exfat
* fuse is used anyway, this is useless

Change-Id: I12c639ff59b141e59bb23c40a6ef04b0518568a8
2014-09-01 22:17:54 -05:00
Dan Pasanen 82fe1b6e3f leds-an30259a: POWERING pattern: match blue and green patterns
* gives a more uniform pulse effect

Change-Id: If563d7089a65a9d8c0c739288e3e9ab19a83a78d
2014-08-30 18:57:52 -05:00
Spegelius 620e2b7c1d Added jactive support
- added jactive_eur_defconfig
- conditionalized code so jactive and jf kernels can be built
  from same source

Change-Id: Id51e47db3ca6d9574131ff3119dfda1685a5f00e
2014-08-28 20:16:28 +03:00
Nick Kralevich 00a32fdf32 staging: android: ram_console: honor dmesg_restrict
The Linux kernel has a setting called dmesg_restrict. When true,
only processes with CAP_SYSLOG can view the kernel dmesg logs. This
helps prevent leaking of kernel information into user space.

On Android, it's possible to bypass these restrictions by viewing
/proc/last_kmsg.

This change makes /proc/last_kmsg require the same permissions as
dmesg.

CC: Android Kernel Team <kernel-team@android.com>
Signed-off-by: Nick Kralevich <nnk@google.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-27 17:37:32 -05:00
Linux Build Service Account 882879a080 Merge "Merge "target/rd: Refactor rd_build_device_space + rd_release_device_space"" 2014-08-27 06:20:47 -07:00
Linux Build Service Account 959354ad20 Merge "target/rd: Refactor rd_build_device_space + rd_release_device_space" 2014-08-26 10:09:28 -07:00
Chao Yu 1286222fd3 f2fs: use for_each_set_bit to simplify the code
This patch uses for_each_set_bit to simplify some codes in f2fs.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:44 -05:00
Chao Yu c6465f1b84 f2fs: add f2fs_balance_fs for expand_inode_data
This patch adds f2fs_balance_fs in expand_inode_data to avoid allocation failure
with segment.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:43 -05:00
Chao Yu 687795e9ff f2fs: invalidate xattr node page when evict inode
When inode is evicted, all the page cache belong to this inode should be
released including the xattr node page. But previously we didn't do this, this
patch fixed this issue.

v2:
 o reposition invalidate_mapping_pages() to the right place suggested by
Jaegeuk Kim.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:42 -05:00
Chao Yu e38609a21a f2fs: avoid skipping recover_inline_xattr after recover_inline_data
When we recover data of inode in roll-forward procedure, and the inode has both
inline data and inline xattr. We may skip recovering inline xattr if we recover
inline data form node page first.
This patch will fix the problem that we lost inline xattr data in above
scenario.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:40 -05:00
Chao Yu 8dd14b5969 f2fs: add tracepoint for f2fs_direct_IO
This patch adds a tracepoint for f2fs_direct_IO.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>

Conflicts:
	fs/f2fs/data.c

Change-Id: I4153a8bd8bd5fb46c42c2917ec3405e3b4a4dce8
2014-08-25 20:39:39 -05:00
Chao Yu c778632275 f2fs: reduce competition among node page writes
We do not need to block on ->node_write among different node page writers e.g.
fsync/flush, unless we have a node page writer from write_checkpoint.
So it's better use rw_semaphore instead of mutex type for ->node_write to
promote performance.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:38 -05:00
Jaegeuk Kim 2ce1c249cc f2fs: fix coding style
This patch fixes wrong coding style.

Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:36 -05:00
Dongho Sim 29aeb976bd f2fs: remove redundant lines in allocate_data_block
There are redundant lines in allocate_data_block.

In this function, we call refresh_sit_entry with old seg and old curseg.
After that, we call locate_dirty_segment with old curseg.

But, the new address is always allocated from old curseg and
we call locate_dirty_segment with old curseg in refresh_sit_entry.
So, we do not need to call locate_dirty_segment with old curseg again.

We've discussed like below:

Jaegeuk said:
 "When considering SSR, we need to take care of the following scenario.
  - old segno : X
  - new address : Z
  - old curseg : Y
  This means, a new block is supposed to be written to Z from X.
  And Z is newly allocated in the same path from Y.

  In that case, we should trigger locate_dirty_segment for Y, since
  it was a current_segment and can be dirty owing to SSR.
  But that was not included in the dirty list."

Changman said:
 "We already choosed old curseg(Y) and then we allocate new address(Z) from old
  curseg(Y). After that we call refresh_sit_entry(old address, new address).
  In the funcation, we call locate_dirty_segment with old seg and old curseg.
  So calling locate_dirty_segment after refresh_sit_entry again is redundant."

Jaegeuk said:
 "Right. The new address is always allocated from old_curseg."

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Dongho Sim <dh.sim@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:35 -05:00
Jaegeuk Kim 1987664576 f2fs: add tracepoint for f2fs_issue_flush
This patch adds a tracepoint for f2fs_issue_flush.

Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:33 -05:00
Jaegeuk Kim d1b534e07a f2fs: test before set/clear bits
If the bit is already set, we don't need to reset it, and vice versa.
Because we don't need to make the caches dirty for that.

Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:32 -05:00
Jaegeuk Kim ad130bf854 f2fs: fix wrong condition for unlikely
This patch fixes the wrongly used unlikely condition.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:31 -05:00
Jaegeuk Kim 0e92579111 f2fs: enable in-place-update for fdatasync
This patch enforces in-place-updates only when fdatasync is requested.
If we adopt this in-place-updates for the fdatasync, we can skip to write the
recovery information.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:30 -05:00
Jaegeuk Kim 70ac7e38b2 f2fs: skip unnecessary data writes during fsync
This patch intends to improve the fsync performance by skipping remaining the
recovery information, only when there is no data that we should recover.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:28 -05:00
Jaegeuk Kim 0e4d815b50 f2fs: add info of appended or updated data writes
This patch introduces a inode number list in which represents inodes having
appended data writes or updated data writes after last checkpoint.
This will be used at fsync to determine whether the recovery information
should be written or not.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>

Conflicts:
	fs/f2fs/inode.c

Change-Id: I94293cce161b66f4ac5f66dea230b9613aa9d68a
2014-08-25 20:39:27 -05:00
Jaegeuk Kim a932385171 f2fs: use radix_tree for ino management
For better ino management, this patch replaces the data structure from list
to radix tree.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:26 -05:00
Jaegeuk Kim 9cead7ca3b f2fs: add infra for ino management
This patch changes the naming of orphan-related data structures to use as
inode numbers managed globally.
Later, we can use this facility for managing any inode number lists.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:24 -05:00
Jaegeuk Kim 291d8d4963 f2fs: punch the core function for inode management
This patch punches out the core functions to manage the inode numbers.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:23 -05:00
Jaegeuk Kim eb86e01ac9 f2fs: add nobarrier mount option
This patch adds a mount option, nobarrier, in f2fs.
The assumption in here is that file system keeps the IO ordering, but
doesn't care about cache flushes inside the storages.

Reviewed-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>

Conflicts:
	Documentation/filesystems/f2fs.txt

Change-Id: I2947cb10128efcf5647eff432d5fd959b2d2f5bc
2014-08-25 20:39:22 -05:00
Chao Yu a00434d373 f2fs: fix to put root inode in error path of fill_super
We should put root inode correctly in error path of fill_super, otherwise we
may encounter a leak case of inode resource.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Reviewed-by: Gu Zheng <guz.fnst@cn.fujitsu.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:20 -05:00
Huang Ying 83278e5f81 f2fs: add f2fs_balance_fs for direct IO
Otherwise, if a large amount of direct IO writes were done, the
segment allocation may be failed because no enough segments are gced.

Changes:

v2: add f2fs_balance_fs into __get_data_block instead of f2fs_direct_IO.

Signed-off-by: Huang, Ying <ying.huang@intel.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:19 -05:00
Chao Yu 79ad5180e7 f2fs: reduce searching region of segmap when free section
In __set_test_and_free we will check whether all segment are free in one section
When free one segment, in order to set section to free status.
But the searching region of segmap is from start segno to last segno of f2fs,
it's not necessary. So let's just only check all segment bitmap of target
section.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
2014-08-25 20:39:18 -05:00
Nicholas Bellinger 8de94fb373 target/rd: Refactor rd_build_device_space + rd_release_device_space
This patch refactors rd_build_device_space() + rd_release_device_space()
into rd_allocate_sgl_table() + rd_release_device_space() so that they
may be used seperatly for setup + release of protection information
scatterlists.

Also add explicit memset of pages within rd_allocate_sgl_table() based
upon passed 'init_payload' value.

v2 changes:
  - Drop unused sg_table from rd_release_device_space (Wei)

Change-Id: I0d42113c0e2d703fe7567a804003b034fd4fa0b7
Cc: Martin K. Petersen <martin.petersen@oracle.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Hannes Reinecke <hare@suse.de>
Cc: Sagi Grimberg <sagig@mellanox.com>
Cc: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Git-commit:4442dc8a92b8f9ad8ee9e7f8438f4c04c03a22dc
Git-repo:https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git
[ggober@codeaurora.org:resolve trivial merge conflicts in target_core_rd.c]
Signed-off-by: Gopal G Goberu <ggober@codeaurora.org>
2014-08-25 12:55:24 -07:00
Kees Cook cd5c18f38b vsprintf: ignore %n again
This ignores %n in printf again, as was originally documented.
Implementing %n poses a greater security risk than utility, so it should
stay ignored.  To help anyone attempting to use %n, a warning will be
emitted if it is encountered.

Based on an earlier patch by Joe Perches.

Because %n was designed to write to pointers on the stack, it has been
frequently used as an attack vector when bugs are found that leak
user-controlled strings into functions that ultimately process format
strings.  While this class of bug can still be turned into an
information leak, removing %n eliminates the common method of elevating
such a bug into an arbitrary kernel memory writing primitive,
significantly reducing the danger of this class of bug.

For seq_file users that need to know the length of a written string for
padding, please see seq_setwidth() and seq_pad() instead.

Signed-off-by: Kees Cook <keescook@chromium.org>
Cc: Joe Perches <joe@perches.com>
Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: 9196436ab2f713b823a2ba2024cb69f40b2f54a5
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
CRs-fixed: 665291
Change-Id: Id191acaf66e3c395df92b0a77331269b525e3cad
Signed-off-by: David Brown <davidb@codeaurora.org>
2014-08-25 12:47:43 -07:00
Tetsuo Handa 5ac504e070 seq_file: introduce seq_setwidth() and seq_pad()
There are several users who want to know bytes written by seq_*() for
alignment purpose.  Currently they are using %n format for knowing it
because seq_*() returns 0 on success.

This patch introduces seq_setwidth() and seq_pad() for allowing them to
align without using %n format.

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: Kees Cook <keescook@chromium.org>
Cc: Joe Perches <joe@perches.com>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: 839cc2a94cc3665bafe32203c2f095f4dd470a80)
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
CRs-fixed: 665291
Change-Id: I727d9af5ed320d717295c9d0f82c88623fb181c1
Signed-off-by: David Brown <davidb@codeaurora.org>
2014-08-25 12:47:39 -07:00
Tetsuo Handa 588af24928 seq_file: remove "%n" usage from seq_file users
All seq_printf() users are using "%n" for calculating padding size,
convert them to use seq_setwidth() / seq_pad() pair.

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: Kees Cook <keescook@chromium.org>
Cc: Joe Perches <joe@perches.com>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: 652586df95e5d76b37d07a11839126dcfede1621
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[rsiddoji@codeaurora.org: Resolve merge conflicts with ipv4/6 ping
 changes in upstream]
CRs-fixed: 665291
Change-Id: Ia0416c9dbe3d80ff35f24f9c93c3543d1200a327
Signed-off-by: Ravi Kumar <rsiddoji@codeaurora.org>
2014-08-25 12:47:35 -07:00
invisiblek 5ce057a676 Merge remote-tracking branch 'caf/LNX.LA.2.7.4' into cm-11.0
Conflicts:
	arch/arm/mm/dma-mapping.c
	net/ipv4/ping.c

Change-Id: I03a8fa452a663e48d27ed4f18bc3b7dd4e6a5855
2014-08-19 22:00:59 -05:00
Dan Pasanen 1de220a313 jf: regen defconfig
Change-Id: I4cdf23a4209875e8d6ac7ee6c0596d02b13c0542
2014-08-19 19:27:30 -05:00
Drew Davis 60dd82eee2 jf: merge GT-I9505_KK_Opensource_Update9
Conflicts:
	drivers/staging/android/binder.c
	fs/buffer.c
	net/ipv4/ping.c
	security/selinux/ss/services.c

Change-Id: I88606d5ec9e6cb0cf0dc3d182c5932d5a993d48b
2014-08-19 19:23:27 -05:00
Dan Pasanen ed8fa659c4 Merge remote-tracking branch 'invisiblek/cafkorg' into cm-11.0 2014-08-19 19:23:10 -05:00
Scott Mertz 5f271100a5 Merge "jf: report SW_LID instead of SW_FLIP" into cm-11.0 2014-08-19 17:02:21 +00:00
Dan Pasanen a4a5cdddff Merge "jf: insidesecure vpn: goodbye" into cm-11.0 2014-08-19 03:53:33 +00:00
Roman Birg a517d2d76a jf: report SW_LID instead of SW_FLIP
Change-Id: Iebffbabdbb3748eec4f887ebd227c67adf01d8ef
Signed-off-by: Roman Birg <roman@cyngn.com>
Signed-off-by: Scott Mertz <smertz@cyngn.com>
2014-08-18 14:13:30 -07:00
Dan Pasanen da029a5106 Revert "iommu/core: pass a user-provided token to fault handlers"
This reverts commit a58bee5bb2.

Conflicts:
	drivers/media/video/msm/vfe/msm_vfe32.c

Change-Id: Ic558a862ab929b9a1dac3ce99556d95f487f5ead
2014-08-18 15:04:30 -05:00
Dan Pasanen 3e85ab93ec Revert "ARM: Add support for 64 bit register reads/writes"
This reverts commit f934a7d049.

Change-Id: Ide6474feeab9513012a6b7004974e9211ed51aa3
2014-08-18 15:04:30 -05:00
Dan Pasanen af4859ba84 Revert "msm: scm-pas: Provide a strongly ordered buffer to the secure world"
This reverts commit 10751a4a2d.

Change-Id: I72377068d8b4407e374616ed2c4e4f33bf5d5c90
2014-08-18 15:04:29 -05:00
Dan Pasanen b4de5c870a Revert "msm: scm: Add scm_call_atomic3"
This reverts commit d1b060368f.

Change-Id: If488e88a4271d86565e5be4f59280ec2188396b5
2014-08-18 15:04:29 -05:00
Hareesh Gundu 71c367bc20 Revert "Execute shader on wakeup from power collapse"
This reverts commit 28eabf6987.

Conflicts:

	drivers/gpu/msm/adreno.c
	drivers/gpu/msm/adreno.h
	drivers/gpu/msm/adreno_a3xx.c
	drivers/gpu/msm/adreno_ringbuffer.c

Change-Id: I0a979f33d9030546d1e72b63cff88d269f63a4c7
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
2014-08-18 15:04:29 -05:00
Dan Pasanen 6a33464fe7 Revert "msm: kgsl: Add separate GPU shader memory mapping"
This reverts commit 7ad8ff977a.

Conflicts:
	arch/arm/mach-msm/iommu_domains.c

Change-Id: Ifd513fe3a235652f25e1a93af9e3b31740444982
2014-08-18 15:04:29 -05:00
Dan Pasanen 31be854053 drivers: gpu: s/msm2/msm/
* back to mainline msm

Change-Id: I5003557a1e22570d4c5cb1dee72e608a9015ee06
2014-08-18 15:04:29 -05:00
Drew Davis d7c4d7f4d3 jf: insidesecure vpn: goodbye
Change-Id: I7a6a2ba068a13a6371636c2fb5f60a485284d7df
2014-08-18 09:10:48 -05:00
Dan Pasanen a1e42ec0e7 Merge "net: wireless: bcmdhd: Enable IPv6 RA filter feature" into cm-11.0 2014-08-17 23:53:26 +00:00
Dan Pasanen ed434951b6 Merge changes I782cda58,I71da0c8b,Ib22ebc43 into cm-11.0
* changes:
  panel: samsung-octa: flash hot pink for underruns
  jf: mdp: fix mdp bandwidth
  msm_fb: display: get mdp bandwidth parameters from board file
2014-08-17 01:44:58 +00:00
Shareef Ali d51f189cfc Merge "jf: JC: allow non samsung app to update firmware" into cm-11.0 2014-08-16 22:09:04 +00:00
Dan Pasanen 0c272b2b06 panel: samsung-octa: flash hot pink for underruns
* while annoying, it'll help debugging

Change-Id: I782cda58705fc483bc7d36bfca2d4af6ff0e401d
2014-08-16 15:58:18 -05:00