Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 9867
b: refs/heads/master
c: 3384a04
h: refs/heads/master
i:
  9865: a7d63a4
  9863: c5c3576
v: v3
  • Loading branch information
Linus Torvalds committed Oct 13, 2005
1 parent a94ef4e commit 614f690
Show file tree
Hide file tree
Showing 72 changed files with 1,082 additions and 968 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 74e52aa561d5bb973075c2015133546b42cdc290
refs/heads/master: 3384a04ed42c583755226374e1ff6a53db7f27c3
44 changes: 44 additions & 0 deletions trunk/Documentation/connector/connector.txt
Original file line number Diff line number Diff line change
Expand Up @@ -131,3 +131,47 @@ Netlink itself is not reliable protocol, that means that messages can
be lost due to memory pressure or process' receiving queue overflowed,
so caller is warned must be prepared. That is why struct cn_msg [main
connector's message header] contains u32 seq and u32 ack fields.

/*****************************************/
Userspace usage.
/*****************************************/
2.6.14 has a new netlink socket implementation, which by default does not
allow to send data to netlink groups other than 1.
So, if to use netlink socket (for example using connector)
with different group number userspace application must subscribe to
that group. It can be achieved by following pseudocode:

s = socket(PF_NETLINK, SOCK_DGRAM, NETLINK_CONNECTOR);

l_local.nl_family = AF_NETLINK;
l_local.nl_groups = 12345;
l_local.nl_pid = 0;

if (bind(s, (struct sockaddr *)&l_local, sizeof(struct sockaddr_nl)) == -1) {
perror("bind");
close(s);
return -1;
}

{
int on = l_local.nl_groups;
setsockopt(s, 270, 1, &on, sizeof(on));
}

Where 270 above is SOL_NETLINK, and 1 is a NETLINK_ADD_MEMBERSHIP socket
option. To drop multicast subscription one should call above socket option
with NETLINK_DROP_MEMBERSHIP parameter which is defined as 0.

2.6.14 netlink code only allows to select a group which is less or equal to
the maximum group number, which is used at netlink_kernel_create() time.
In case of connector it is CN_NETLINK_USERS + 0xf, so if you want to use
group number 12345, you must increment CN_NETLINK_USERS to that number.
Additional 0xf numbers are allocated to be used by non-in-kernel users.

Due to this limitation, group 0xffffffff does not work now, so one can
not use add/remove connector's group notifications, but as far as I know,
only cn_test.c test module used it.

Some work in netlink area is still being done, so things can be changed in
2.6.15 timeframe, if it will happen, documentation will be updated for that
kernel.
2 changes: 1 addition & 1 deletion trunk/arch/arm/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ tune-$(CONFIG_CPU_ARM926T) :=-mtune=arm9tdmi
tune-$(CONFIG_CPU_SA110) :=-mtune=strongarm110
tune-$(CONFIG_CPU_SA1100) :=-mtune=strongarm1100
tune-$(CONFIG_CPU_XSCALE) :=$(call cc-option,-mtune=xscale,-mtune=strongarm110) -Wa,-mcpu=xscale
tune-$(CONFIG_CPU_V6) :=-mtune=strongarm
tune-$(CONFIG_CPU_V6) :=$(call cc-option,-mtune=arm1136j-s,-mtune=strongarm)

# Need -Uarm for gcc < 3.x
CFLAGS_ABI :=$(call cc-option,-mapcs-32,-mabi=apcs-gnu) $(call cc-option,-mno-thumb-interwork,)
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/arm/kernel/armksyms.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ extern void fp_enter(void);

#define EXPORT_SYMBOL_ALIAS(sym,orig) \
EXPORT_CRC_ALIAS(sym) \
const struct kernel_symbol __ksymtab_##sym \
__attribute__((section("__ksymtab"))) = \
static const struct kernel_symbol __ksymtab_##sym \
__attribute_used__ __attribute__((section("__ksymtab"))) = \
{ (unsigned long)&orig, #sym };

/*
Expand Down
7 changes: 1 addition & 6 deletions trunk/arch/arm/kernel/entry-common.S
Original file line number Diff line number Diff line change
Expand Up @@ -106,15 +106,10 @@ ENTRY(ret_from_fork)
.endm

.Larm700bug:
ldr r0, [sp, #S_PSR] @ Get calling cpsr
sub lr, lr, #4
str lr, [r8]
msr spsr_cxsf, r0
ldmia sp, {r0 - lr}^ @ Get calling r0 - lr
mov r0, r0
ldr lr, [sp, #S_PC] @ Get PC
add sp, sp, #S_FRAME_SIZE
movs pc, lr
subs pc, lr, #4
#else
.macro arm710_bug_check, instr, temp
.endm
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/arm/mach-s3c2410/mach-anubis.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ static int external_map[] = { 2 };
static int chip0_map[] = { 0 };
static int chip1_map[] = { 1 };

struct mtd_partition anubis_default_nand_part[] = {
static struct mtd_partition anubis_default_nand_part[] = {
[0] = {
.name = "Boot Agent",
.size = SZ_16K,
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/arm/mach-s3c2410/mach-bast.c
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ static int chip0_map[] = { 1 };
static int chip1_map[] = { 2 };
static int chip2_map[] = { 3 };

struct mtd_partition bast_default_nand_part[] = {
static struct mtd_partition bast_default_nand_part[] = {
[0] = {
.name = "Boot Agent",
.size = SZ_16K,
Expand Down Expand Up @@ -340,7 +340,7 @@ static struct resource bast_dm9k_resource[] = {
* better IO routines can be written and tested
*/

struct dm9000_plat_data bast_dm9k_platdata = {
static struct dm9000_plat_data bast_dm9k_platdata = {
.flags = DM9000_PLATF_16BITONLY
};

Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/arm/mach-s3c2410/mach-vr1000.c
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ static struct resource vr1000_dm9k1_resource[] = {
* better IO routines can be written and tested
*/

struct dm9000_plat_data vr1000_dm9k_platdata = {
static struct dm9000_plat_data vr1000_dm9k_platdata = {
.flags = DM9000_PLATF_16BITONLY,
};

Expand Down
3 changes: 0 additions & 3 deletions trunk/arch/arm/mach-s3c2410/s3c2410.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,6 @@ static struct platform_device *uart_devices[] __initdata = {
&s3c_uart2
};

/* store our uart devices for the serial driver console */
struct platform_device *s3c2410_uart_devices[3];

static int s3c2410_uart_count = 0;

/* uart registration process */
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/arm/mach-s3c2410/s3c2440.c
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ void __init s3c2440_init_uarts(struct s3c2410_uartcfg *cfg, int no)

#ifdef CONFIG_PM

struct sleep_save s3c2440_sleep[] = {
static struct sleep_save s3c2440_sleep[] = {
SAVE_ITEM(S3C2440_DSC0),
SAVE_ITEM(S3C2440_DSC1),
SAVE_ITEM(S3C2440_GPJDAT),
Expand Down Expand Up @@ -260,7 +260,7 @@ void __init s3c2440_init_clocks(int xtal)
* as a driver which may support both 2410 and 2440 may try and use it.
*/

int __init s3c2440_core_init(void)
static int __init s3c2440_core_init(void)
{
return sysdev_class_register(&s3c2440_sysclass);
}
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-s3c2410/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
#include <asm/hardware/clock.h>

#include "clock.h"
#include "cpu.h"

static unsigned long timer_startval;
static unsigned long timer_usec_ticks;
Expand Down
44 changes: 22 additions & 22 deletions trunk/arch/arm/mm/alignment.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,15 +111,15 @@ proc_alignment_read(char *page, char **start, off_t off, int count, int *eof,
}

static int proc_alignment_write(struct file *file, const char __user *buffer,
unsigned long count, void *data)
unsigned long count, void *data)
{
char mode;

if (count > 0) {
if (get_user(mode, buffer))
return -EFAULT;
if (mode >= '0' && mode <= '5')
ai_usermode = mode - '0';
ai_usermode = mode - '0';
}
return count;
}
Expand Down Expand Up @@ -262,7 +262,7 @@ union offset_union {
goto fault; \
} while (0)

#define put32_unaligned_check(val,addr) \
#define put32_unaligned_check(val,addr) \
__put32_unaligned_check("strb", val, addr)

#define put32t_unaligned_check(val,addr) \
Expand Down Expand Up @@ -306,19 +306,19 @@ do_alignment_ldrhstrh(unsigned long addr, unsigned long instr, struct pt_regs *r
return TYPE_LDST;

user:
if (LDST_L_BIT(instr)) {
unsigned long val;
get16t_unaligned_check(val, addr);
if (LDST_L_BIT(instr)) {
unsigned long val;
get16t_unaligned_check(val, addr);

/* signed half-word? */
if (instr & 0x40)
val = (signed long)((signed short) val);
/* signed half-word? */
if (instr & 0x40)
val = (signed long)((signed short) val);

regs->uregs[rd] = val;
} else
put16t_unaligned_check(regs->uregs[rd], addr);
regs->uregs[rd] = val;
} else
put16t_unaligned_check(regs->uregs[rd], addr);

return TYPE_LDST;
return TYPE_LDST;

fault:
return TYPE_FAULT;
Expand All @@ -342,11 +342,11 @@ do_alignment_ldrdstrd(unsigned long addr, unsigned long instr,
unsigned long val;
get32_unaligned_check(val, addr);
regs->uregs[rd] = val;
get32_unaligned_check(val, addr+4);
regs->uregs[rd+1] = val;
get32_unaligned_check(val, addr + 4);
regs->uregs[rd + 1] = val;
} else {
put32_unaligned_check(regs->uregs[rd], addr);
put32_unaligned_check(regs->uregs[rd+1], addr+4);
put32_unaligned_check(regs->uregs[rd + 1], addr + 4);
}

return TYPE_LDST;
Expand All @@ -356,11 +356,11 @@ do_alignment_ldrdstrd(unsigned long addr, unsigned long instr,
unsigned long val;
get32t_unaligned_check(val, addr);
regs->uregs[rd] = val;
get32t_unaligned_check(val, addr+4);
regs->uregs[rd+1] = val;
get32t_unaligned_check(val, addr + 4);
regs->uregs[rd + 1] = val;
} else {
put32t_unaligned_check(regs->uregs[rd], addr);
put32t_unaligned_check(regs->uregs[rd+1], addr+4);
put32t_unaligned_check(regs->uregs[rd + 1], addr + 4);
}

return TYPE_LDST;
Expand Down Expand Up @@ -443,7 +443,7 @@ do_alignment_ldmstm(unsigned long addr, unsigned long instr, struct pt_regs *reg
if (LDST_P_EQ_U(instr)) /* U = P */
eaddr += 4;

/*
/*
* For alignment faults on the ARM922T/ARM920T the MMU makes
* the FSR (and hence addr) equal to the updated base address
* of the multiple access rather than the restored value.
Expand Down Expand Up @@ -570,7 +570,7 @@ thumb2arm(u16 tinstr)
/* 6.5.1 Format 3: */
case 0x4800 >> 11: /* 7.1.28 LDR(3) */
/* NOTE: This case is not technically possible. We're
* loading 32-bit memory data via PC relative
* loading 32-bit memory data via PC relative
* addressing mode. So we can and should eliminate
* this case. But I'll leave it here for now.
*/
Expand Down Expand Up @@ -642,7 +642,7 @@ do_alignment(unsigned long addr, unsigned int fsr, struct pt_regs *regs)

if (fault) {
type = TYPE_FAULT;
goto bad_or_fault;
goto bad_or_fault;
}

if (user_mode(regs))
Expand Down
5 changes: 0 additions & 5 deletions trunk/arch/arm/nwfpe/fpa11.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,6 @@
#include <linux/string.h>
#include <asm/system.h>

/* forward declarations */
unsigned int EmulateCPDO(const unsigned int);
unsigned int EmulateCPDT(const unsigned int);
unsigned int EmulateCPRT(const unsigned int);

/* Reset the FPA11 chip. Called to initialize and reset the emulator. */
static void resetFPA11(void)
{
Expand Down
20 changes: 20 additions & 0 deletions trunk/arch/arm/nwfpe/fpa11.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,4 +95,24 @@ extern int8 SetRoundingMode(const unsigned int);
extern int8 SetRoundingPrecision(const unsigned int);
extern void nwfpe_init_fpa(union fp_state *fp);

extern unsigned int EmulateAll(unsigned int opcode);

extern unsigned int EmulateCPDT(const unsigned int opcode);
extern unsigned int EmulateCPDO(const unsigned int opcode);
extern unsigned int EmulateCPRT(const unsigned int opcode);

/* fpa11_cpdt.c */
extern unsigned int PerformLDF(const unsigned int opcode);
extern unsigned int PerformSTF(const unsigned int opcode);
extern unsigned int PerformLFM(const unsigned int opcode);
extern unsigned int PerformSFM(const unsigned int opcode);

/* single_cpdo.c */

extern unsigned int SingleCPDO(struct roundingData *roundData,
const unsigned int opcode, FPREG * rFd);
/* double_cpdo.c */
extern unsigned int DoubleCPDO(struct roundingData *roundData,
const unsigned int opcode, FPREG * rFd);

#endif
3 changes: 1 addition & 2 deletions trunk/arch/arm/nwfpe/fpa11_cprt.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,11 @@
#include "fpa11.inl"
#include "fpmodule.h"
#include "fpmodule.inl"
#include "softfloat.h"

#ifdef CONFIG_FPE_NWFPE_XP
extern flag floatx80_is_nan(floatx80);
#endif
extern flag float64_is_nan(float64);
extern flag float32_is_nan(float32);

unsigned int PerformFLT(const unsigned int opcode);
unsigned int PerformFIX(const unsigned int opcode);
Expand Down
6 changes: 6 additions & 0 deletions trunk/arch/arm/nwfpe/fpopcode.h
Original file line number Diff line number Diff line change
Expand Up @@ -476,4 +476,10 @@ static inline unsigned int getDestinationSize(const unsigned int opcode)
return (nRc);
}

extern unsigned int checkCondition(const unsigned int opcode,
const unsigned int ccodes);

extern const float64 float64Constant[];
extern const float32 float32Constant[];

#endif
3 changes: 3 additions & 0 deletions trunk/arch/arm/nwfpe/softfloat.h
Original file line number Diff line number Diff line change
Expand Up @@ -265,4 +265,7 @@ static inline flag float64_lt_nocheck(float64 a, float64 b)
return (a != b) && (aSign ^ (a < b));
}

extern flag float32_is_nan( float32 a );
extern flag float64_is_nan( float64 a );

#endif
2 changes: 2 additions & 0 deletions trunk/arch/cris/arch-v32/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
#include <linux/kernel.h>
#include <linux/cpumask.h>
#include <linux/interrupt.h>
#include <linux/module.h>

#define IPI_SCHEDULE 1
#define IPI_CALL 2
Expand All @@ -28,6 +29,7 @@ spinlock_t cris_atomic_locks[] = { [0 ... LOCK_COUNT - 1] = SPIN_LOCK_UNLOCKED};
/* CPU masks */
cpumask_t cpu_online_map = CPU_MASK_NONE;
cpumask_t phys_cpu_present_map = CPU_MASK_NONE;
EXPORT_SYMBOL(phys_cpu_present_map);

/* Variables used during SMP boot */
volatile int cpu_now_booting = 0;
Expand Down
5 changes: 3 additions & 2 deletions trunk/arch/ppc/kernel/cputable.c
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ struct cpu_spec cpu_specs[] = {
.cpu_features = CPU_FTR_COMMON | CPU_FTR_601 |
CPU_FTR_HPTE_TABLE,
.cpu_user_features = COMMON_PPC | PPC_FEATURE_601_INSTR |
PPC_FEATURE_UNIFIED_CACHE,
PPC_FEATURE_UNIFIED_CACHE | PPC_FEATURE_NO_TB,
.icache_bsize = 32,
.dcache_bsize = 32,
.cpu_setup = __setup_cpu_601
Expand Down Expand Up @@ -745,7 +745,8 @@ struct cpu_spec cpu_specs[] = {
.cpu_name = "403GCX",
.cpu_features = CPU_FTR_SPLIT_ID_CACHE |
CPU_FTR_USE_TB,
.cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
.cpu_user_features = PPC_FEATURE_32 |
PPC_FEATURE_HAS_MMU | PPC_FEATURE_NO_TB,
.icache_bsize = 16,
.dcache_bsize = 16,
},
Expand Down
3 changes: 3 additions & 0 deletions trunk/arch/sh/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#include <linux/time.h>
#include <linux/timex.h>
#include <linux/sched.h>
#include <linux/module.h>

#include <asm/atomic.h>
#include <asm/processor.h>
Expand All @@ -39,6 +40,8 @@ struct sh_cpuinfo cpu_data[NR_CPUS];
extern void per_cpu_trap_init(void);

cpumask_t cpu_possible_map;
EXPORT_SYMBOL(cpu_possible_map);

cpumask_t cpu_online_map;
static atomic_t cpus_booted = ATOMIC_INIT(0);

Expand Down
Loading

0 comments on commit 614f690

Please sign in to comment.