Skip to content

Commit

Permalink
Merge branch 'akpm' (patches from Andrew)
Browse files Browse the repository at this point in the history
Merge third patchbomb from Andrew Morton:

 - various misc things

 - a couple of lib/ optimisations

 - provide DIV_ROUND_CLOSEST_ULL()

 - checkpatch updates

 - rtc tree

 - befs, nilfs2, hfs, hfsplus, fatfs, adfs, affs, bfs

 - ptrace fixes

 - fork() fixes

 - seccomp cleanups

 - more mmap_sem hold time reductions from Davidlohr

* emailed patches from Andrew Morton <[email protected]>: (138 commits)
  proc: show locks in /proc/pid/fdinfo/X
  docs: add missing and new /proc/PID/status file entries, fix typos
  drivers/rtc/rtc-at91rm9200.c: make IO endian agnostic
  Documentation/spi/spidev_test.c: fix warning
  drivers/rtc/rtc-s5m.c: allow usage on device type different than main MFD type
  .gitignore: ignore *.tar
  MAINTAINERS: add Mediatek SoC mailing list
  tomoyo: reduce mmap_sem hold for mm->exe_file
  powerpc/oprofile: reduce mmap_sem hold for exe_file
  oprofile: reduce mmap_sem hold for mm->exe_file
  mips: ip32: add platform data hooks to use DS1685 driver
  lib/Kconfig: fix up HAVE_ARCH_BITREVERSE help text
  x86: switch to using asm-generic for seccomp.h
  sparc: switch to using asm-generic for seccomp.h
  powerpc: switch to using asm-generic for seccomp.h
  parisc: switch to using asm-generic for seccomp.h
  mips: switch to using asm-generic for seccomp.h
  microblaze: use asm-generic for seccomp.h
  arm: use asm-generic for seccomp.h
  seccomp: allow COMPAT sigreturn overrides
  ...
  • Loading branch information
torvalds committed Apr 17, 2015
2 parents 4fc8adc + 6c8c903 commit 54e514b
Show file tree
Hide file tree
Showing 158 changed files with 2,190 additions and 1,551 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
*.order
*.elf
*.bin
*.tar
*.gz
*.bz2
*.lzma
Expand Down
13 changes: 13 additions & 0 deletions Documentation/CodingStyle
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,19 @@ macros using parameters.
#define CONSTANT 0x4000
#define CONSTEXP (CONSTANT | 3)

5) namespace collisions when defining local variables in macros resembling
functions:

#define FOO(x) \
({ \
typeof(x) ret; \
ret = calc_ret(x); \
(ret); \
)}

ret is a common name for a local variable - __foo_ret is less likely
to collide with an existing variable.

The cpp manual deals with macros exhaustively. The gcc internals manual also
covers RTL which is used frequently with assembly language in the kernel.

Expand Down
4 changes: 2 additions & 2 deletions Documentation/SubmittingPatches
Original file line number Diff line number Diff line change
Expand Up @@ -614,8 +614,8 @@ The canonical patch message body contains the following:

- An empty line.

- The body of the explanation, which will be copied to the
permanent changelog to describe this patch.
- The body of the explanation, line wrapped at 75 columns, which will
be copied to the permanent changelog to describe this patch.

- The "Signed-off-by:" lines, described above, which will
also go in the changelog.
Expand Down
17 changes: 17 additions & 0 deletions Documentation/devicetree/bindings/rtc/digicolor-rtc.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Conexant Digicolor Real Time Clock controller

This binding currently supports the CX92755 SoC.

Required properties:
- compatible: should be "cnxt,cx92755-rtc"
- reg: physical base address of the controller and length of memory mapped
region.
- interrupts: rtc alarm interrupt

Example:

rtc@f0000c30 {
compatible = "cnxt,cx92755-rtc";
reg = <0xf0000c30 0x18>;
interrupts = <25>;
};
5 changes: 5 additions & 0 deletions Documentation/devicetree/bindings/rtc/stmp3xxx-rtc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ Required properties:
region.
- interrupts: rtc alarm interrupt

Optional properties:
- stmp,crystal-freq: override crystal frequency as determined from fuse bits.
Only <32000> and <32768> are possible for the hardware. Use <0> for
"no crystal".

Example:

rtc@80056000 {
Expand Down
15 changes: 12 additions & 3 deletions Documentation/filesystems/proc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -200,26 +200,31 @@ contains details information about the process itself. Its fields are
explained in Table 1-4.

(for SMP CONFIG users)
For making accounting scalable, RSS related information are handled in
asynchronous manner and the vaule may not be very precise. To see a precise
For making accounting scalable, RSS related information are handled in an
asynchronous manner and the value may not be very precise. To see a precise
snapshot of a moment, you can see /proc/<pid>/smaps file and scan page table.
It's slow but very precise.

Table 1-2: Contents of the status files (as of 2.6.30-rc7)
Table 1-2: Contents of the status files (as of 3.20.0)
..............................................................................
Field Content
Name filename of the executable
State state (R is running, S is sleeping, D is sleeping
in an uninterruptible wait, Z is zombie,
T is traced or stopped)
Tgid thread group ID
Ngid NUMA group ID (0 if none)
Pid process id
PPid process id of the parent process
TracerPid PID of process tracing this process (0 if not)
Uid Real, effective, saved set, and file system UIDs
Gid Real, effective, saved set, and file system GIDs
FDSize number of file descriptor slots currently allocated
Groups supplementary group list
NStgid descendant namespace thread group ID hierarchy
NSpid descendant namespace process ID hierarchy
NSpgid descendant namespace process group ID hierarchy
NSsid descendant namespace session ID hierarchy
VmPeak peak virtual memory size
VmSize total program size
VmLck locked memory size
Expand Down Expand Up @@ -1704,6 +1709,10 @@ A typical output is
flags: 0100002
mnt_id: 19

All locks associated with a file descriptor are shown in its fdinfo too.

lock: 1: FLOCK ADVISORY WRITE 359 00:13:11691 0 EOF

The files such as eventfd, fsnotify, signalfd, epoll among the regular pos/flags
pair provide additional information particular to the objects they represent.

Expand Down
4 changes: 2 additions & 2 deletions Documentation/spi/spidev_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ static void hex_dump(const void *src, size_t length, size_t line_size, char *pre
* Unescape - process hexadecimal escape character
* converts shell input "\x23" -> 0x23
*/
int unespcape(char *_dst, char *_src, size_t len)
static int unescape(char *_dst, char *_src, size_t len)
{
int ret = 0;
char *src = _src;
Expand Down Expand Up @@ -304,7 +304,7 @@ int main(int argc, char *argv[])
size = strlen(input_tx+1);
tx = malloc(size);
rx = malloc(size);
size = unespcape((char *)tx, input_tx, size);
size = unescape((char *)tx, input_tx, size);
transfer(fd, tx, rx, size);
free(rx);
free(tx);
Expand Down
21 changes: 21 additions & 0 deletions Documentation/sysctl/kernel.txt
Original file line number Diff line number Diff line change
Expand Up @@ -872,6 +872,27 @@ can be ORed together:

==============================================================

threads-max

This value controls the maximum number of threads that can be created
using fork().

During initialization the kernel sets this value such that even if the
maximum number of threads is created, the thread structures occupy only
a part (1/8th) of the available RAM pages.

The minimum value that can be written to threads-max is 20.
The maximum value that can be written to threads-max is given by the
constant FUTEX_TID_MASK (0x3fffffff).
If a value outside of this range is written to threads-max an error
EINVAL occurs.

The value written is checked against the available RAM pages. If the
thread structures would occupy too much (more than 1/8th) of the
available RAM pages threads-max is reduced accordingly.

==============================================================

unknown_nmi_panic:

The value in this file affects behavior of handling NMI. When the
Expand Down
2 changes: 2 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -1215,6 +1215,7 @@ F: arch/arm/mach-orion5x/ts78xx-*
ARM/Mediatek SoC support
M: Matthias Brugger <[email protected]>
L: [email protected] (moderated for non-subscribers)
L: [email protected] (moderated for non-subscribers)
S: Maintained
F: arch/arm/boot/dts/mt6*
F: arch/arm/boot/dts/mt8*
Expand Down Expand Up @@ -8183,6 +8184,7 @@ X: kernel/torture.c

REAL TIME CLOCK (RTC) SUBSYSTEM
M: Alessandro Zummo <[email protected]>
M: Alexandre Belloni <[email protected]>
L: [email protected]
Q: http://patchwork.ozlabs.org/project/rtc-linux/list/
S: Maintained
Expand Down
1 change: 1 addition & 0 deletions arch/alpha/include/asm/processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ struct task_struct;
extern unsigned long thread_saved_pc(struct task_struct *);

/* Do necessary setup to start up a newly executed thread. */
struct pt_regs;
extern void start_thread(struct pt_regs *, unsigned long, unsigned long);

/* Free all resources held by a thread. */
Expand Down
3 changes: 1 addition & 2 deletions arch/arc/kernel/troubleshoot.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ static void show_callee_regs(struct callee_regs *cregs)
print_reg_file(&(cregs->r13), 13);
}

void print_task_path_n_nm(struct task_struct *tsk, char *buf)
static void print_task_path_n_nm(struct task_struct *tsk, char *buf)
{
struct path path;
char *path_nm = NULL;
Expand All @@ -77,7 +77,6 @@ void print_task_path_n_nm(struct task_struct *tsk, char *buf)
done:
pr_info("Path: %s\n", path_nm);
}
EXPORT_SYMBOL(print_task_path_n_nm);

static void show_faulting_vma(unsigned long address, char *buf)
{
Expand Down
1 change: 1 addition & 0 deletions arch/arm/include/asm/Kbuild
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ generic-y += preempt.h
generic-y += resource.h
generic-y += rwsem.h
generic-y += scatterlist.h
generic-y += seccomp.h
generic-y += sections.h
generic-y += segment.h
generic-y += sembuf.h
Expand Down
11 changes: 0 additions & 11 deletions arch/arm/include/asm/seccomp.h

This file was deleted.

8 changes: 1 addition & 7 deletions arch/microblaze/include/asm/seccomp.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,8 @@

#include <linux/unistd.h>

#define __NR_seccomp_read __NR_read
#define __NR_seccomp_write __NR_write
#define __NR_seccomp_exit __NR_exit
#define __NR_seccomp_sigreturn __NR_sigreturn

#define __NR_seccomp_read_32 __NR_read
#define __NR_seccomp_write_32 __NR_write
#define __NR_seccomp_exit_32 __NR_exit
#define __NR_seccomp_sigreturn_32 __NR_sigreturn
#include <asm-generic/seccomp.h>

#endif /* _ASM_MICROBLAZE_SECCOMP_H */
3 changes: 2 additions & 1 deletion arch/mips/configs/ip32_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ CONFIG_RTC_CLASS=y
# CONFIG_RTC_HCTOSYS is not set
# CONFIG_RTC_INTF_SYSFS is not set
# CONFIG_RTC_INTF_PROC is not set
CONFIG_RTC_DRV_CMOS=y
CONFIG_RTC_DRV_DS1685_FAMILY=y
CONFIG_RTC_DRV_DS1685=y
CONFIG_EXT2_FS=y
CONFIG_EXT2_FS_XATTR=y
CONFIG_EXT2_FS_POSIX_ACL=y
Expand Down
36 changes: 0 additions & 36 deletions arch/mips/include/asm/mach-ip32/mc146818rtc.h

This file was deleted.

7 changes: 2 additions & 5 deletions arch/mips/include/asm/seccomp.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

#include <linux/unistd.h>

#define __NR_seccomp_read __NR_read
#define __NR_seccomp_write __NR_write
#define __NR_seccomp_exit __NR_exit
#define __NR_seccomp_sigreturn __NR_rt_sigreturn

/*
* Kludge alert:
*
Expand All @@ -29,4 +24,6 @@

#endif /* CONFIG_MIPS32_O32 */

#include <asm-generic/seccomp.h>

#endif /* __ASM_SECCOMP_H */
46 changes: 39 additions & 7 deletions arch/mips/sgi-ip32/ip32-platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,13 @@
#include <linux/init.h>
#include <linux/platform_device.h>
#include <linux/serial_8250.h>
#include <linux/rtc/ds1685.h>

#include <asm/ip32/mace.h>
#include <asm/ip32/ip32_ints.h>

extern void ip32_prepare_poweroff(void);

#define MACEISA_SERIAL1_OFFS offsetof(struct sgi_mace, isa.serial1)
#define MACEISA_SERIAL2_OFFS offsetof(struct sgi_mace, isa.serial2)

Expand Down Expand Up @@ -90,18 +93,47 @@ static __init int sgio2btns_devinit(void)

device_initcall(sgio2btns_devinit);

static struct resource sgio2_cmos_rsrc[] = {
#define MACE_RTC_RES_START (MACE_BASE + offsetof(struct sgi_mace, isa.rtc))
#define MACE_RTC_RES_END (MACE_RTC_RES_START + 32767)

static struct resource ip32_rtc_resources[] = {
{
.start = 0x70,
.end = 0x71,
.flags = IORESOURCE_IO
.start = MACEISA_RTC_IRQ,
.end = MACEISA_RTC_IRQ,
.flags = IORESOURCE_IRQ
}, {
.start = MACE_RTC_RES_START,
.end = MACE_RTC_RES_END,
.flags = IORESOURCE_MEM,
}
};

static __init int sgio2_cmos_devinit(void)
/* RTC registers on IP32 are each padded by 256 bytes (0x100). */
static struct ds1685_rtc_platform_data
ip32_rtc_platform_data[] = {
{
.regstep = 0x100,
.bcd_mode = true,
.no_irq = false,
.uie_unsupported = false,
.alloc_io_resources = true,
.plat_prepare_poweroff = ip32_prepare_poweroff,
},
};

struct platform_device ip32_rtc_device = {
.name = "rtc-ds1685",
.id = -1,
.dev = {
.platform_data = ip32_rtc_platform_data,
},
.num_resources = ARRAY_SIZE(ip32_rtc_resources),
.resource = ip32_rtc_resources,
};

+static int __init sgio2_rtc_devinit(void)
{
return IS_ERR(platform_device_register_simple("rtc_cmos", -1,
sgio2_cmos_rsrc, 1));
return platform_device_register(&ip32_rtc_device);
}

device_initcall(sgio2_cmos_devinit);
Expand Down
Loading

0 comments on commit 54e514b

Please sign in to comment.