Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 65135
b: refs/heads/master
c: 6d3105d
h: refs/heads/master
i:
  65133: 82924ca
  65131: 462b923
  65127: 481d262
  65119: e95fb7e
v: v3
  • Loading branch information
Stephen Hemminger authored and Jeff Garzik committed Sep 25, 2007
1 parent 3a5aedf commit 2c57177
Show file tree
Hide file tree
Showing 7 changed files with 36 additions and 15 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: bbbd2bf00bab467cff7b1f418b2cb24c71291f59
refs/heads/master: 6d3105d5388c359882068b161b431ab3db4b3721
26 changes: 18 additions & 8 deletions trunk/drivers/char/mspec.c
Original file line number Diff line number Diff line change
Expand Up @@ -155,22 +155,23 @@ mspec_open(struct vm_area_struct *vma)
* mspec_close
*
* Called when unmapping a device mapping. Frees all mspec pages
* belonging to all the vma's sharing this vma_data structure.
* belonging to the vma.
*/
static void
mspec_close(struct vm_area_struct *vma)
{
struct vma_data *vdata;
int index, last_index;
int index, last_index, result;
unsigned long my_page;

vdata = vma->vm_private_data;

if (!atomic_dec_and_test(&vdata->refcnt))
return;
BUG_ON(vma->vm_start < vdata->vm_start || vma->vm_end > vdata->vm_end);

last_index = (vdata->vm_end - vdata->vm_start) >> PAGE_SHIFT;
for (index = 0; index < last_index; index++) {
spin_lock(&vdata->lock);
index = (vma->vm_start - vdata->vm_start) >> PAGE_SHIFT;
last_index = (vma->vm_end - vdata->vm_start) >> PAGE_SHIFT;
for (; index < last_index; index++) {
if (vdata->maddr[index] == 0)
continue;
/*
Expand All @@ -179,19 +180,28 @@ mspec_close(struct vm_area_struct *vma)
*/
my_page = vdata->maddr[index];
vdata->maddr[index] = 0;
if (!mspec_zero_block(my_page, PAGE_SIZE))
spin_unlock(&vdata->lock);
result = mspec_zero_block(my_page, PAGE_SIZE);
if (!result)
uncached_free_page(my_page);
else
printk(KERN_WARNING "mspec_close(): "
"failed to zero page %ld\n", my_page);
"failed to zero page %i\n",
result);
spin_lock(&vdata->lock);
}
spin_unlock(&vdata->lock);

if (!atomic_dec_and_test(&vdata->refcnt))
return;

if (vdata->flags & VMD_VMALLOCED)
vfree(vdata);
else
kfree(vdata);
}


/*
* mspec_nopfn
*
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/lguest/lguest_asm.S
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@
jmp lguest_init

/*G:055 We create a macro which puts the assembler code between lgstart_ and
* lgend_ markers. These templates are put in the .text section: they can't be
* discarded after boot as we may need to patch modules, too. */
.text
* lgend_ markers. These templates end up in the .init.text section, so they
* are discarded after boot. */
#define LGUEST_PATCH(name, insns...) \
lgstart_##name: insns; lgend_##name:; \
.globl lgstart_##name; .globl lgend_##name
Expand All @@ -35,6 +34,7 @@ LGUEST_PATCH(popf, movl %eax, lguest_data+LGUEST_DATA_irq_enabled)
LGUEST_PATCH(pushf, movl lguest_data+LGUEST_DATA_irq_enabled, %eax)
/*:*/

.text
/* These demark the EIP range where host should never deliver interrupts. */
.global lguest_noirq_start
.global lguest_noirq_end
Expand Down
10 changes: 10 additions & 0 deletions trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,16 @@ static void sky2_phy_init(struct sky2_hw *hw, unsigned port)
if (!(hw->flags & SKY2_HW_GIGABIT)) {
/* enable automatic crossover */
ctrl |= PHY_M_PC_MDI_XMODE(PHY_M_PC_ENA_AUTO) >> 1;

if (hw->chip_id == CHIP_ID_YUKON_FE_P &&
hw->chip_rev == CHIP_REV_YU_FE2_A0) {
u16 spec;

/* Enable Class A driver for FE+ A0 */
spec = gm_phy_read(hw, port, PHY_MARV_FE_SPEC_2);
spec |= PHY_M_FESC_SEL_CL_A;
gm_phy_write(hw, port, PHY_MARV_FE_SPEC_2, spec);
}
} else {
/* disable energy detect */
ctrl &= ~PHY_M_PC_EN_DET_MSK;
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/w1/w1.c
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,6 @@ static int w1_uevent(struct device *dev, char **envp, int num_envp,
err = add_uevent_var(envp, num_envp, &cur_index, buffer, buffer_size,
&cur_len, "W1_SLAVE_ID=%024LX",
(unsigned long long)sl->reg_num.id);
envp[cur_index] = NULL;
if (err)
return err;

Expand Down
4 changes: 3 additions & 1 deletion trunk/fs/ufs/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -894,7 +894,7 @@ static int ufs_fill_super(struct super_block *sb, void *data, int silent)
goto again;
}

sbi->s_flags = flags;/*after that line some functions use s_flags*/

ufs_print_super_stuff(sb, usb1, usb2, usb3);

/*
Expand Down Expand Up @@ -1025,6 +1025,8 @@ static int ufs_fill_super(struct super_block *sb, void *data, int silent)
UFS_MOUNT_UFSTYPE_44BSD)
uspi->s_maxsymlinklen =
fs32_to_cpu(sb, usb3->fs_un2.fs_44.fs_maxsymlinklen);

sbi->s_flags = flags;

inode = iget(sb, UFS_ROOTINO);
if (!inode || is_bad_inode(inode))
Expand Down
2 changes: 1 addition & 1 deletion trunk/lib/Kconfig.debug
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ config LOCKDEP
select KALLSYMS_ALL

config LOCK_STAT
bool "Lock usage statistics"
bool "Lock usage statisitics"
depends on DEBUG_KERNEL && TRACE_IRQFLAGS_SUPPORT && STACKTRACE_SUPPORT && LOCKDEP_SUPPORT
select LOCKDEP
select DEBUG_SPINLOCK
Expand Down

0 comments on commit 2c57177

Please sign in to comment.