Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 63607
b: refs/heads/master
c: 2f08123
h: refs/heads/master
i:
  63605: 00cb2ed
  63603: d2e2cc0
  63599: 67041eb
v: v3
  • Loading branch information
Michal Piotrowski authored and David S. Miller committed Aug 3, 2007
1 parent ebedf89 commit a7c64ec
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 23 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: 3ff42e4f13095f5351fe651b8a591e67aabbb1a6
refs/heads/master: 2f0812350e0e34f583919470b0517c2e368ee048
20 changes: 7 additions & 13 deletions trunk/drivers/firewire/fw-ohci.c
Original file line number Diff line number Diff line change
Expand Up @@ -907,8 +907,6 @@ static void bus_reset_tasklet(unsigned long data)
int self_id_count, i, j, reg;
int generation, new_generation;
unsigned long flags;
void *free_rom = NULL;
dma_addr_t free_rom_bus = 0;

reg = reg_read(ohci, OHCI1394_NodeID);
if (!(reg & OHCI1394_NodeID_idValid)) {
Expand Down Expand Up @@ -972,8 +970,8 @@ static void bus_reset_tasklet(unsigned long data)
*/

if (ohci->next_config_rom != NULL) {
free_rom = ohci->config_rom;
free_rom_bus = ohci->config_rom_bus;
dma_free_coherent(ohci->card.device, CONFIG_ROM_SIZE,
ohci->config_rom, ohci->config_rom_bus);
ohci->config_rom = ohci->next_config_rom;
ohci->config_rom_bus = ohci->next_config_rom_bus;
ohci->next_config_rom = NULL;
Expand All @@ -992,10 +990,6 @@ static void bus_reset_tasklet(unsigned long data)

spin_unlock_irqrestore(&ohci->lock, flags);

if (free_rom)
dma_free_coherent(ohci->card.device, CONFIG_ROM_SIZE,
free_rom, free_rom_bus);

fw_core_handle_bus_reset(&ohci->card, ohci->node_id, generation,
self_id_count, ohci->self_id_buffer);
}
Expand Down Expand Up @@ -1192,7 +1186,7 @@ ohci_set_config_rom(struct fw_card *card, u32 *config_rom, size_t length)
{
struct fw_ohci *ohci;
unsigned long flags;
int retval = -EBUSY;
int retval = 0;
__be32 *next_config_rom;
dma_addr_t next_config_rom_bus;

Expand Down Expand Up @@ -1246,7 +1240,10 @@ ohci_set_config_rom(struct fw_card *card, u32 *config_rom, size_t length)

reg_write(ohci, OHCI1394_ConfigROMmap,
ohci->next_config_rom_bus);
retval = 0;
} else {
dma_free_coherent(ohci->card.device, CONFIG_ROM_SIZE,
next_config_rom, next_config_rom_bus);
retval = -EBUSY;
}

spin_unlock_irqrestore(&ohci->lock, flags);
Expand All @@ -1260,9 +1257,6 @@ ohci_set_config_rom(struct fw_card *card, u32 *config_rom, size_t length)
*/
if (retval == 0)
fw_core_initiate_bus_reset(&ohci->card, 1);
else
dma_free_coherent(ohci->card.device, CONFIG_ROM_SIZE,
next_config_rom, next_config_rom_bus);

return retval;
}
Expand Down
5 changes: 1 addition & 4 deletions trunk/drivers/firewire/fw-sbp2.c
Original file line number Diff line number Diff line change
Expand Up @@ -984,7 +984,6 @@ static int sbp2_scsi_queuecommand(struct scsi_cmnd *cmd, scsi_done_fn_t done)
struct fw_unit *unit = sd->unit;
struct fw_device *device = fw_device(unit->device.parent);
struct sbp2_command_orb *orb;
unsigned max_payload;

/*
* Bidirectional commands are not yet implemented, and unknown
Expand Down Expand Up @@ -1018,10 +1017,8 @@ static int sbp2_scsi_queuecommand(struct scsi_cmnd *cmd, scsi_done_fn_t done)
* specifies the max payload size as 2 ^ (max_payload + 2), so
* if we set this to max_speed + 7, we get the right value.
*/
max_payload = min(device->max_speed + 7,
device->card->max_receive - 1);
orb->request.misc =
COMMAND_ORB_MAX_PAYLOAD(max_payload) |
COMMAND_ORB_MAX_PAYLOAD(device->max_speed + 7) |
COMMAND_ORB_SPEED(device->max_speed) |
COMMAND_ORB_NOTIFY;

Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/firewire/fw-transaction.c
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ fw_core_handle_response(struct fw_card *card, struct fw_packet *p)
}
EXPORT_SYMBOL(fw_core_handle_response);

static const struct fw_address_region topology_map_region =
const struct fw_address_region topology_map_region =
{ .start = 0xfffff0001000ull, .end = 0xfffff0001400ull, };

static void
Expand Down Expand Up @@ -772,7 +772,7 @@ static struct fw_address_handler topology_map = {
.address_callback = handle_topology_map,
};

static const struct fw_address_region registers_region =
const struct fw_address_region registers_region =
{ .start = 0xfffff0000000ull, .end = 0xfffff0000400ull, };

static void
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/firewire/fw-transaction.h
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ struct fw_card {
unsigned long reset_jiffies;

unsigned long long guid;
unsigned max_receive;
int max_receive;
int link_speed;
int config_rom_generation;

Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/ieee1394/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ config IEEE1394_SBP2

config IEEE1394_SBP2_PHYS_DMA
bool "Enable replacement for physical DMA in SBP2"
depends on IEEE1394_SBP2 && VIRT_TO_BUS && EXPERIMENTAL
depends on IEEE1394 && IEEE1394_SBP2 && EXPERIMENTAL && (X86_32 || PPC_32)
help
This builds sbp2 for use with non-OHCI host adapters which do not
support physical DMA or for when ohci1394 is run with phys_dma=0.
Expand Down
5 changes: 5 additions & 0 deletions trunk/drivers/ieee1394/sbp2.c
Original file line number Diff line number Diff line change
Expand Up @@ -773,6 +773,11 @@ static struct sbp2_lu *sbp2_alloc_device(struct unit_directory *ud)
SBP2_ERR("failed to register lower 4GB address range");
goto failed_alloc;
}
#else
if (dma_set_mask(hi->host->device.parent, DMA_32BIT_MASK)) {
SBP2_ERR("failed to set 4GB DMA mask");
goto failed_alloc;
}
#endif
}

Expand Down
1 change: 0 additions & 1 deletion trunk/net/wanrouter/wanmain.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
#include <linux/capability.h>
#include <linux/errno.h> /* return codes */
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/module.h> /* support for loadable modules */
#include <linux/slab.h> /* kmalloc(), kfree() */
#include <linux/mm.h>
Expand Down

0 comments on commit a7c64ec

Please sign in to comment.