Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 142986
b: refs/heads/master
c: da76166
h: refs/heads/master
v: v3
  • Loading branch information
David Howells committed Apr 10, 2009
1 parent a1b8c7f commit dbb2dbd
Show file tree
Hide file tree
Showing 287 changed files with 1,251 additions and 942 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: 5de4c51d2a859a1556b7d20ae1278c3e2d70a79b
refs/heads/master: da7616610c8d2ec16a8ada44216e836e5fcbd08b
45 changes: 0 additions & 45 deletions trunk/Documentation/infiniband/ipoib.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,49 +24,6 @@ Partitions and P_Keys
The P_Key for any interface is given by the "pkey" file, and the
main interface for a subinterface is in "parent."

Datagram vs Connected modes

The IPoIB driver supports two modes of operation: datagram and
connected. The mode is set and read through an interface's
/sys/class/net/<intf name>/mode file.

In datagram mode, the IB UD (Unreliable Datagram) transport is used
and so the interface MTU has is equal to the IB L2 MTU minus the
IPoIB encapsulation header (4 bytes). For example, in a typical IB
fabric with a 2K MTU, the IPoIB MTU will be 2048 - 4 = 2044 bytes.

In connected mode, the IB RC (Reliable Connected) transport is used.
Connected mode is to takes advantage of the connected nature of the
IB transport and allows an MTU up to the maximal IP packet size of
64K, which reduces the number of IP packets needed for handling
large UDP datagrams, TCP segments, etc and increases the performance
for large messages.

In connected mode, the interface's UD QP is still used for multicast
and communication with peers that don't support connected mode. In
this case, RX emulation of ICMP PMTU packets is used to cause the
networking stack to use the smaller UD MTU for these neighbours.

Stateless offloads

If the IB HW supports IPoIB stateless offloads, IPoIB advertises
TCP/IP checksum and/or Large Send (LSO) offloading capability to the
network stack.

Large Receive (LRO) offloading is also implemented and may be turned
on/off using ethtool calls. Currently LRO is supported only for
checksum offload capable devices.

Stateless offloads are supported only in datagram mode.

Interrupt moderation

If the underlying IB device supports CQ event moderation, one can
use ethtool to set interrupt mitigation parameters and thus reduce
the overhead incurred by handling interrupts. The main code path of
IPoIB doesn't use events for TX completion signaling so only RX
moderation is supported.

Debugging Information

By compiling the IPoIB driver with CONFIG_INFINIBAND_IPOIB_DEBUG set
Expand Down Expand Up @@ -98,5 +55,3 @@ References
http://ietf.org/rfc/rfc4391.txt
IP over InfiniBand (IPoIB) Architecture (RFC 4392)
http://ietf.org/rfc/rfc4392.txt
IP over InfiniBand: Connected Mode (RFC 4755)
http://ietf.org/rfc/rfc4755.txt
28 changes: 14 additions & 14 deletions trunk/arch/mn10300/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -105,31 +105,31 @@ endif
###################################################################################################

# processor specific definitions
include/asm-mn10300/.proc: $(wildcard include/config/proc/*.h) include/config/auto.conf
@echo ' SYMLINK include/asm-mn10300/proc -> include/asm-mn10300/proc-$(PROCESSOR)'
arch/mn10300/include/asm/.proc: $(wildcard include/config/proc/*.h) include/config/auto.conf
@echo ' SYMLINK arch/mn10300/include/asm/proc -> arch/mn10300/include/asm/proc-$(PROCESSOR)'
ifneq ($(KBUILD_SRC),)
$(Q)mkdir -p include/asm-mn10300
$(Q)ln -fsn $(srctree)/include/asm-mn10300/proc-$(PROCESSOR) include/asm-mn10300/proc
$(Q)mkdir -p arch/mn10300/include/asm
$(Q)ln -fsn $(srctree)/arch/mn10300/include/asm/proc-$(PROCESSOR) arch/mn10300/include/asm/proc
else
$(Q)ln -fsn proc-$(PROCESSOR) include/asm-mn10300/proc
$(Q)ln -fsn proc-$(PROCESSOR) arch/mn10300/include/asm/proc
endif
@touch $@

CLEAN_FILES += include/asm-mn10300/proc include/asm-mn10300/.proc
CLEAN_FILES += arch/mn10300/include/asm/proc arch/mn10300/include/asm/.proc

prepare: include/asm-mn10300/.proc
prepare: arch/mn10300/include/asm/.proc

# unit specific definitions
include/asm-mn10300/.unit: $(wildcard include/config/unit/*.h) include/config/auto.conf
@echo ' SYMLINK include/asm-mn10300/unit -> include/asm-mn10300/unit-$(UNIT)'
arch/mn10300/include/asm/.unit: $(wildcard include/config/unit/*.h) include/config/auto.conf
@echo ' SYMLINK arch/mn10300/include/asm/unit -> arch/mn10300/include/asm/unit-$(UNIT)'
ifneq ($(KBUILD_SRC),)
$(Q)mkdir -p include/asm-mn10300
$(Q)ln -fsn $(srctree)/include/asm-mn10300/unit-$(UNIT) include/asm-mn10300/unit
$(Q)mkdir -p arch/mn10300/include/asm
$(Q)ln -fsn $(srctree)/arch/mn10300/include/asm/unit-$(UNIT) arch/mn10300/include/asm/unit
else
$(Q)ln -fsn unit-$(UNIT) include/asm-mn10300/unit
$(Q)ln -fsn unit-$(UNIT) arch/mn10300/include/asm/unit
endif
@touch $@

CLEAN_FILES += include/asm-mn10300/unit include/asm-mn10300/.unit
CLEAN_FILES += arch/mn10300/include/asm/unit arch/mn10300/include/asm/.unit

prepare: include/asm-mn10300/.unit
prepare: arch/mn10300/include/asm/.unit
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions trunk/arch/x86/include/asm/fixmap.h
Original file line number Diff line number Diff line change
Expand Up @@ -151,11 +151,11 @@ extern pte_t *pkmap_page_table;

void __native_set_fixmap(enum fixed_addresses idx, pte_t pte);
void native_set_fixmap(enum fixed_addresses idx,
phys_addr_t phys, pgprot_t flags);
unsigned long phys, pgprot_t flags);

#ifndef CONFIG_PARAVIRT
static inline void __set_fixmap(enum fixed_addresses idx,
phys_addr_t phys, pgprot_t flags)
unsigned long phys, pgprot_t flags)
{
native_set_fixmap(idx, phys, flags);
}
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/x86/include/asm/paravirt.h
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ struct pv_mmu_ops {
/* Sometimes the physical address is a pfn, and sometimes its
an mfn. We can tell which is which from the index. */
void (*set_fixmap)(unsigned /* enum fixed_addresses */ idx,
phys_addr_t phys, pgprot_t flags);
unsigned long phys, pgprot_t flags);
};

struct raw_spinlock;
Expand Down Expand Up @@ -1432,7 +1432,7 @@ static inline void arch_leave_lazy_mmu_mode(void)
void arch_flush_lazy_mmu_mode(void);

static inline void __set_fixmap(unsigned /* enum fixed_addresses */ idx,
phys_addr_t phys, pgprot_t flags)
unsigned long phys, pgprot_t flags)
{
pv_mmu_ops.set_fixmap(idx, phys, flags);
}
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/x86/mm/pgtable.c
Original file line number Diff line number Diff line change
Expand Up @@ -345,8 +345,7 @@ void __native_set_fixmap(enum fixed_addresses idx, pte_t pte)
fixmaps_set++;
}

void native_set_fixmap(enum fixed_addresses idx, phys_addr_t phys,
pgprot_t flags)
void native_set_fixmap(enum fixed_addresses idx, unsigned long phys, pgprot_t flags)
{
__native_set_fixmap(idx, pfn_pte(phys >> PAGE_SHIFT, flags));
}
2 changes: 1 addition & 1 deletion trunk/arch/x86/xen/mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -1750,7 +1750,7 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
}
#endif /* CONFIG_X86_64 */

static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
static void xen_set_fixmap(unsigned idx, unsigned long phys, pgprot_t prot)
{
pte_t pte;

Expand Down
12 changes: 6 additions & 6 deletions trunk/drivers/block/xsysace.c
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,7 @@ static void ace_fsm_dostate(struct ace_device *ace)
case ACE_FSM_STATE_IDENTIFY_PREPARE:
/* Send identify command */
ace->fsm_task = ACE_TASK_IDENTIFY;
ace->data_ptr = ace->cf_id;
ace->data_ptr = &ace->cf_id;
ace->data_count = ACE_BUF_PER_SECTOR;
ace_out(ace, ACE_SECCNTCMD, ACE_SECCNTCMD_IDENTIFY);

Expand Down Expand Up @@ -608,8 +608,8 @@ static void ace_fsm_dostate(struct ace_device *ace)
break;

case ACE_FSM_STATE_IDENTIFY_COMPLETE:
ace_fix_driveid(ace->cf_id);
ace_dump_mem(ace->cf_id, 512); /* Debug: Dump out disk ID */
ace_fix_driveid(&ace->cf_id[0]);
ace_dump_mem(&ace->cf_id, 512); /* Debug: Dump out disk ID */

if (ace->data_result) {
/* Error occured, disable the disk */
Expand All @@ -622,9 +622,9 @@ static void ace_fsm_dostate(struct ace_device *ace)

/* Record disk parameters */
set_capacity(ace->gd,
ata_id_u32(ace->cf_id, ATA_ID_LBA_CAPACITY));
ata_id_u32(&ace->cf_id, ATA_ID_LBA_CAPACITY));
dev_info(ace->dev, "capacity: %i sectors\n",
ata_id_u32(ace->cf_id, ATA_ID_LBA_CAPACITY));
ata_id_u32(&ace->cf_id, ATA_ID_LBA_CAPACITY));
}

/* We're done, drop to IDLE state and notify waiters */
Expand Down Expand Up @@ -923,7 +923,7 @@ static int ace_release(struct gendisk *disk, fmode_t mode)
static int ace_getgeo(struct block_device *bdev, struct hd_geometry *geo)
{
struct ace_device *ace = bdev->bd_disk->private_data;
u16 *cf_id = ace->cf_id;
u16 *cf_id = &ace->cf_id[0];

dev_dbg(ace->dev, "ace_getgeo()\n");

Expand Down
91 changes: 88 additions & 3 deletions trunk/drivers/ide/at91_ide.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
*
*/

#include <linux/version.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/clk.h>
Expand Down Expand Up @@ -174,6 +175,90 @@ static void at91_ide_output_data(ide_drive_t *drive, struct ide_cmd *cmd,
leave_16bit(chipselect, mode);
}

static u8 ide_mm_inb(unsigned long port)
{
return readb((void __iomem *) port);
}

static void ide_mm_outb(u8 value, unsigned long port)
{
writeb(value, (void __iomem *) port);
}

static void at91_ide_tf_load(ide_drive_t *drive, struct ide_cmd *cmd)
{
ide_hwif_t *hwif = drive->hwif;
struct ide_io_ports *io_ports = &hwif->io_ports;
struct ide_taskfile *tf = &cmd->tf;
u8 HIHI = (cmd->tf_flags & IDE_TFLAG_LBA48) ? 0xE0 : 0xEF;

if (cmd->ftf_flags & IDE_FTFLAG_FLAGGED)
HIHI = 0xFF;

if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE)
ide_mm_outb(tf->hob_feature, io_ports->feature_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_NSECT)
ide_mm_outb(tf->hob_nsect, io_ports->nsect_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_LBAL)
ide_mm_outb(tf->hob_lbal, io_ports->lbal_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_LBAM)
ide_mm_outb(tf->hob_lbam, io_ports->lbam_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_LBAH)
ide_mm_outb(tf->hob_lbah, io_ports->lbah_addr);

if (cmd->tf_flags & IDE_TFLAG_OUT_FEATURE)
ide_mm_outb(tf->feature, io_ports->feature_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_NSECT)
ide_mm_outb(tf->nsect, io_ports->nsect_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_LBAL)
ide_mm_outb(tf->lbal, io_ports->lbal_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_LBAM)
ide_mm_outb(tf->lbam, io_ports->lbam_addr);
if (cmd->tf_flags & IDE_TFLAG_OUT_LBAH)
ide_mm_outb(tf->lbah, io_ports->lbah_addr);

if (cmd->tf_flags & IDE_TFLAG_OUT_DEVICE)
ide_mm_outb((tf->device & HIHI) | drive->select, io_ports->device_addr);
}

static void at91_ide_tf_read(ide_drive_t *drive, struct ide_cmd *cmd)
{
ide_hwif_t *hwif = drive->hwif;
struct ide_io_ports *io_ports = &hwif->io_ports;
struct ide_taskfile *tf = &cmd->tf;

/* be sure we're looking at the low order bits */
ide_mm_outb(ATA_DEVCTL_OBS, io_ports->ctl_addr);

if (cmd->tf_flags & IDE_TFLAG_IN_ERROR)
tf->error = ide_mm_inb(io_ports->feature_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_NSECT)
tf->nsect = ide_mm_inb(io_ports->nsect_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_LBAL)
tf->lbal = ide_mm_inb(io_ports->lbal_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_LBAM)
tf->lbam = ide_mm_inb(io_ports->lbam_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_LBAH)
tf->lbah = ide_mm_inb(io_ports->lbah_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_DEVICE)
tf->device = ide_mm_inb(io_ports->device_addr);

if (cmd->tf_flags & IDE_TFLAG_LBA48) {
ide_mm_outb(ATA_HOB | ATA_DEVCTL_OBS, io_ports->ctl_addr);

if (cmd->tf_flags & IDE_TFLAG_IN_HOB_ERROR)
tf->hob_error = ide_mm_inb(io_ports->feature_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_HOB_NSECT)
tf->hob_nsect = ide_mm_inb(io_ports->nsect_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_HOB_LBAL)
tf->hob_lbal = ide_mm_inb(io_ports->lbal_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_HOB_LBAM)
tf->hob_lbam = ide_mm_inb(io_ports->lbam_addr);
if (cmd->tf_flags & IDE_TFLAG_IN_HOB_LBAH)
tf->hob_lbah = ide_mm_inb(io_ports->lbah_addr);
}
}

static void at91_ide_set_pio_mode(ide_drive_t *drive, const u8 pio)
{
struct ide_timing *timing;
Expand All @@ -199,8 +284,8 @@ static const struct ide_tp_ops at91_ide_tp_ops = {
.write_devctl = ide_write_devctl,

.dev_select = ide_dev_select,
.tf_load = ide_tf_load,
.tf_read = ide_tf_read,
.tf_load = at91_ide_tf_load,
.tf_read = at91_ide_tf_read,

.input_data = at91_ide_input_data,
.output_data = at91_ide_output_data,
Expand All @@ -215,7 +300,7 @@ static const struct ide_port_info at91_ide_port_info __initdata = {
.tp_ops = &at91_ide_tp_ops,
.host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA | IDE_HFLAG_SINGLE |
IDE_HFLAG_NO_IO_32BIT | IDE_HFLAG_UNMASK_IRQS,
.pio_mask = ATA_PIO6,
.pio_mask = ATA_PIO5,
};

/*
Expand Down
13 changes: 4 additions & 9 deletions trunk/drivers/ide/falconide.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include <asm/atarihw.h>
#include <asm/atariints.h>
#include <asm/atari_stdma.h>
#include <asm/ide.h>

#define DRV_NAME "falconide"

Expand Down Expand Up @@ -68,10 +67,8 @@ static void falconide_input_data(ide_drive_t *drive, struct ide_cmd *cmd,
{
unsigned long data_addr = drive->hwif->io_ports.data_addr;

if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS)) {
__ide_mm_insw(data_addr, buf, (len + 1) / 2);
return;
}
if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS))
return insw(data_addr, buf, (len + 1) / 2);

raw_insw_swapw((u16 *)data_addr, buf, (len + 1) / 2);
}
Expand All @@ -81,10 +78,8 @@ static void falconide_output_data(ide_drive_t *drive, struct ide_cmd *cmd,
{
unsigned long data_addr = drive->hwif->io_ports.data_addr;

if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS)) {
__ide_mm_outsw(data_addr, buf, (len + 1) / 2);
return;
}
if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS))
return outsw(data_addr, buf, (len + 1) / 2);

raw_outsw_swapw((u16 *)data_addr, buf, (len + 1) / 2);
}
Expand Down
5 changes: 2 additions & 3 deletions trunk/drivers/ide/ide-acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -318,9 +318,8 @@ static int do_drive_set_taskfiles(ide_drive_t *drive,

/* convert GTF to taskfile */
memset(&cmd, 0, sizeof(cmd));
memcpy(&cmd.tf.feature, gtf, REGS_PER_GTF);
cmd.valid.out.tf = IDE_VALID_OUT_TF | IDE_VALID_DEVICE;
cmd.valid.in.tf = IDE_VALID_IN_TF | IDE_VALID_DEVICE;
memcpy(&cmd.tf_array[7], gtf, REGS_PER_GTF);
cmd.tf_flags = IDE_TFLAG_TF | IDE_TFLAG_DEVICE;

err = ide_no_data_taskfile(drive, &cmd);
if (err) {
Expand Down
Loading

0 comments on commit dbb2dbd

Please sign in to comment.