Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 812
b: refs/heads/master
c: 5cd0c34
h: refs/heads/master
v: v3
  • Loading branch information
Russell King committed May 3, 2005
1 parent b881e74 commit 3e209bf
Show file tree
Hide file tree
Showing 18 changed files with 603 additions and 1,084 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: 52292c9b8c16aa9024a65aaeeca434bb8fec7d24
refs/heads/master: 5cd0c3442021fbf39c7152b341a952aa24054be9
105 changes: 22 additions & 83 deletions trunk/arch/arm/boot/compressed/head.S
Original file line number Diff line number Diff line change
Expand Up @@ -18,48 +18,30 @@
* Please select one of the following when turning on debugging.
*/
#ifdef DEBUG
#if defined(CONFIG_DEBUG_DC21285_PORT)
.macro loadsp, rb
mov \rb, #0x42000000
.endm
.macro writeb, rb
str \rb, [r3, #0x160]
.endm
#elif defined(CONFIG_DEBUG_ICEDCC)

#include <asm/arch/debug-macro.S>

#if defined(CONFIG_DEBUG_ICEDCC)
.macro loadsp, rb
.endm
.macro writeb, rb
mcr p14, 0, \rb, c0, c1, 0
.endm
#elif defined(CONFIG_FOOTBRIDGE)
.macro loadsp, rb
mov \rb, #0x7c000000
.macro writeb, ch, rb
mcr p14, 0, \ch, c0, c1, 0
.endm
.macro writeb, rb
strb \rb, [r3, #0x3f8]
#else
.macro writeb, ch, rb
senduart \ch, \rb
.endm
#elif defined(CONFIG_ARCH_RPC)

#if defined(CONFIG_FOOTBRIDGE) || \
defined(CONFIG_ARCH_RPC) || \
defined(CONFIG_ARCH_INTEGRATOR) || \
defined(CONFIG_ARCH_PXA) || \
defined(CONFIG_ARCH_IXP4XX) || \
defined(CONFIG_ARCH_IXP2000) || \
defined(CONFIG_ARCH_LH7A40X) || \
defined(CONFIG_ARCH_OMAP)
.macro loadsp, rb
mov \rb, #0x03000000
orr \rb, \rb, #0x00010000
.endm
.macro writeb, rb
strb \rb, [r3, #0x3f8 << 2]
.endm
#elif defined(CONFIG_ARCH_INTEGRATOR)
.macro loadsp, rb
mov \rb, #0x16000000
.endm
.macro writeb, rb
strb \rb, [r3, #0]
.endm
#elif defined(CONFIG_ARCH_PXA) /* Xscale-type */
.macro loadsp, rb
mov \rb, #0x40000000
orr \rb, \rb, #0x00100000
.endm
.macro writeb, rb
strb \rb, [r3, #0]
addruart \rb
.endm
#elif defined(CONFIG_ARCH_SA1100)
.macro loadsp, rb
Expand All @@ -70,64 +52,21 @@
add \rb, \rb, #0x00010000 @ Ser1
# endif
.endm
.macro writeb, rb
str \rb, [r3, #0x14] @ UTDR
.endm
#elif defined(CONFIG_ARCH_IXP4XX)
.macro loadsp, rb
mov \rb, #0xc8000000
.endm
.macro writeb, rb
str \rb, [r3, #0]
#elif defined(CONFIG_ARCH_IXP2000)
.macro loadsp, rb
mov \rb, #0xc0000000
orr \rb, \rb, #0x00030000
.endm
.macro writeb, rb
str \rb, [r3, #0]
.endm
#elif defined(CONFIG_ARCH_LH7A40X)
.macro loadsp, rb
ldr \rb, =0x80000700 @ UART2 UARTBASE
.endm
.macro writeb, rb
strb \rb, [r3, #0]
.endm
#elif defined(CONFIG_ARCH_OMAP)
.macro loadsp, rb
mov \rb, #0xff000000 @ physical base address
add \rb, \rb, #0x00fb0000
#if defined(CONFIG_OMAP_LL_DEBUG_UART2) || defined(CONFIG_OMAP_LL_DEBUG_UART3)
add \rb, \rb, #0x00000800
#endif
#ifdef CONFIG_OMAP_LL_DEBUG_UART3
add \rb, \rb, #0x00009000
#endif
.endm
.macro writeb, rb
strb \rb, [r3]
.endm
#elif defined(CONFIG_ARCH_IOP331)
.macro loadsp, rb
mov \rb, #0xff000000
orr \rb, \rb, #0x00ff0000
orr \rb, \rb, #0x0000f700 @ location of the UART
.endm
.macro writeb, rb
str \rb, [r3, #0]
.endm
#elif defined(CONFIG_ARCH_S3C2410)
.macro loadsp, rb
.macro loadsp, rb
mov \rb, #0x50000000
add \rb, \rb, #0x4000 * CONFIG_S3C2410_LOWLEVEL_UART_PORT
.endm
.macro writeb, rb
strb \rb, [r3, #0x20]
.endm
#else
#error no serial architecture defined
#endif
#endif
#endif

.macro kputc,val
Expand Down Expand Up @@ -734,7 +673,7 @@ puts: loadsp r3
1: ldrb r2, [r0], #1
teq r2, #0
moveq pc, lr
2: writeb r2
2: writeb r2, r3
mov r1, #0x00020000
3: subs r1, r1, #1
bne 3b
Expand Down
7 changes: 0 additions & 7 deletions trunk/arch/ppc64/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,19 +56,12 @@ LDFLAGS_vmlinux := -Bstatic -e $(KERNELLOAD) -Ttext $(KERNELLOAD)
CFLAGS += -msoft-float -pipe -mminimal-toc -mtraceback=none \
-mcall-aixdesc

GCC_VERSION := $(call cc-version)
GCC_BROKEN_VEC := $(shell if [ $(GCC_VERSION) -lt 0400 ] ; then echo "y"; fi ;)

ifeq ($(CONFIG_POWER4_ONLY),y)
ifeq ($(CONFIG_ALTIVEC),y)
ifeq ($(GCC_BROKEN_VEC),y)
CFLAGS += $(call cc-option,-mcpu=970)
else
CFLAGS += $(call cc-option,-mcpu=power4)
endif
else
CFLAGS += $(call cc-option,-mcpu=power4)
endif
else
CFLAGS += $(call cc-option,-mtune=power4)
endif
Expand Down
35 changes: 23 additions & 12 deletions trunk/fs/jfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,22 +175,31 @@ jfs_get_blocks(struct inode *ip, sector_t lblock, unsigned long max_blocks,
{
s64 lblock64 = lblock;
int rc = 0;
int take_locks;
xad_t xad;
s64 xaddr;
int xflag;
s32 xlen = max_blocks;
s32 xlen;

/*
* If this is a special inode (imap, dmap)
* the lock should already be taken
*/
take_locks = (JFS_IP(ip)->fileset != AGGREGATE_I);

/*
* Take appropriate lock on inode
*/
if (create)
IWRITE_LOCK(ip);
else
IREAD_LOCK(ip);
if (take_locks) {
if (create)
IWRITE_LOCK(ip);
else
IREAD_LOCK(ip);
}

if (((lblock64 << ip->i_sb->s_blocksize_bits) < ip->i_size) &&
(!xtLookup(ip, lblock64, max_blocks, &xflag, &xaddr, &xlen, 0)) &&
xaddr) {
(xtLookup(ip, lblock64, max_blocks, &xflag, &xaddr, &xlen, 0)
== 0) && xlen) {
if (xflag & XAD_NOTRECORDED) {
if (!create)
/*
Expand Down Expand Up @@ -229,7 +238,7 @@ jfs_get_blocks(struct inode *ip, sector_t lblock, unsigned long max_blocks,
#ifdef _JFS_4K
if ((rc = extHint(ip, lblock64 << ip->i_sb->s_blocksize_bits, &xad)))
goto unlock;
rc = extAlloc(ip, xlen, lblock64, &xad, FALSE);
rc = extAlloc(ip, max_blocks, lblock64, &xad, FALSE);
if (rc)
goto unlock;

Expand All @@ -249,10 +258,12 @@ jfs_get_blocks(struct inode *ip, sector_t lblock, unsigned long max_blocks,
/*
* Release lock on inode
*/
if (create)
IWRITE_UNLOCK(ip);
else
IREAD_UNLOCK(ip);
if (take_locks) {
if (create)
IWRITE_UNLOCK(ip);
else
IREAD_UNLOCK(ip);
}
return rc;
}

Expand Down
12 changes: 6 additions & 6 deletions trunk/fs/jfs/jfs_dmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,6 @@ dbUpdatePMap(struct inode *ipbmap,
struct metapage *mp;
struct jfs_log *log;
int lsn, difft, diffp;
unsigned long flags;

/* the blocks better be within the mapsize. */
if (blkno + nblocks > bmp->db_mapsize) {
Expand Down Expand Up @@ -505,7 +504,6 @@ dbUpdatePMap(struct inode *ipbmap,
0);
if (mp == NULL)
return -EIO;
metapage_wait_for_io(mp);
}
dp = (struct dmap *) mp->data;

Expand Down Expand Up @@ -580,32 +578,34 @@ dbUpdatePMap(struct inode *ipbmap,
if (mp->lsn != 0) {
/* inherit older/smaller lsn */
logdiff(diffp, mp->lsn, log);
LOGSYNC_LOCK(log, flags);
if (difft < diffp) {
mp->lsn = lsn;

/* move bp after tblock in logsync list */
LOGSYNC_LOCK(log);
list_move(&mp->synclist, &tblk->synclist);
LOGSYNC_UNLOCK(log);
}

/* inherit younger/larger clsn */
LOGSYNC_LOCK(log);
logdiff(difft, tblk->clsn, log);
logdiff(diffp, mp->clsn, log);
if (difft > diffp)
mp->clsn = tblk->clsn;
LOGSYNC_UNLOCK(log, flags);
LOGSYNC_UNLOCK(log);
} else {
mp->log = log;
mp->lsn = lsn;

/* insert bp after tblock in logsync list */
LOGSYNC_LOCK(log, flags);
LOGSYNC_LOCK(log);

log->count++;
list_add(&mp->synclist, &tblk->synclist);

mp->clsn = tblk->clsn;
LOGSYNC_UNLOCK(log, flags);
LOGSYNC_UNLOCK(log);
}
}

Expand Down
6 changes: 3 additions & 3 deletions trunk/fs/jfs/jfs_dtree.c
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ static struct metapage *read_index_page(struct inode *inode, s64 blkno)
s32 xlen;

rc = xtLookup(inode, blkno, 1, &xflag, &xaddr, &xlen, 1);
if (rc || (xaddr == 0))
if (rc || (xlen == 0))
return NULL;

return read_metapage(inode, xaddr, PSIZE, 1);
Expand All @@ -231,7 +231,7 @@ static struct metapage *get_index_page(struct inode *inode, s64 blkno)
s32 xlen;

rc = xtLookup(inode, blkno, 1, &xflag, &xaddr, &xlen, 1);
if (rc || (xaddr == 0))
if (rc || (xlen == 0))
return NULL;

return get_metapage(inode, xaddr, PSIZE, 1);
Expand Down Expand Up @@ -3181,7 +3181,7 @@ int jfs_readdir(struct file *filp, void *dirent, filldir_t filldir)
d = (struct ldtentry *) & p->slot[stbl[i]];

if (((long) jfs_dirent + d->namlen + 1) >
(dirent_buf + PAGE_SIZE)) {
(dirent_buf + PSIZE)) {
/* DBCS codepages could overrun dirent_buf */
index = i;
overflow = 1;
Expand Down
Loading

0 comments on commit 3e209bf

Please sign in to comment.