Buildfixes for the blkman -> block_io change. Also fixes the non TRACE_PCI version of the PCI add-on.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12649 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz 2005-05-12 18:09:37 +00:00
parent 7a70a2d6d6
commit 8f3f38367e
7 changed files with 22 additions and 22 deletions

View File

@ -134,7 +134,7 @@ BEOS_ADD_ONS_DRIVERS_GRAPHICS="radeon.driver nv.driver nm.driver mga.driver"
BEOS_ADD_ONS_DRIVERS_NET="ipro1000 rtl8139 rtl8169 sis900 \
via-rhine wb840 net_stack_driver" # bcm440x bcm570x (only available with GPLd add-ons)
BEOS_ADD_ONS_BUS_MANAGERS="pci isa ide scsi config_manager"
BEOS_ADD_ONS_KERNEL_MISC="ide_isa generic_ide_pci blkman fast_log ide_adapter locked_pool \
BEOS_ADD_ONS_KERNEL_MISC="ide_isa generic_ide_pci block_io fast_log ide_adapter locked_pool \
scsi_periph intel keyboard vga_text"
BEOS_ADD_ONS_FILESYSTEMS="bfs"
BEOS_DATA_FILES="timezone_files keymap_files"
@ -252,7 +252,7 @@ for f in $BEOS_ADD_ONS_BUS_MANAGERS; do
$cp ${sPrefix}bus_managers/$f $targetDir/beos/system/add-ons/kernel/bus_managers/$f
done
for f in busses/ide/ide_isa file_systems/bfs generic/blkman generic/fast_log \
for f in busses/ide/ide_isa file_systems/bfs generic/block_io generic/fast_log \
generic/ide_adapter generic/locked_pool generic/scsi_periph \
partitioning_systems/intel console/vga_text busses/ide/generic_ide_pci; do
$cp ${sPrefix}$f $targetDir/beos/system/add-ons/kernel/$f
@ -370,7 +370,7 @@ $cp ${sPrefix}$sourceDir/objects/${arch}.R1/system/zbeos .
echo "Creating boot module links..."
$cd $targetDir/beos/system/add-ons/kernel/boot
for f in bus_managers/config_manager bus_managers/pci bus_managers/isa bus_managers/ide \
bus_managers/scsi busses/ide/ide_isa file_systems/bfs generic/blkman \
bus_managers/scsi busses/ide/ide_isa file_systems/bfs generic/block_io \
generic/fast_log generic/ide_adapter generic/locked_pool generic/scsi_periph \
partitioning_systems/intel busses/ide/generic_ide_pci; do
$ln -fs /boot/beos/system/add-ons/kernel/$f $(basename $f)

View File

@ -18,7 +18,7 @@
#include <string.h>
#include <malloc.h>
#include <blkman.h>
#include <block_io.h>
/** called when an IDE channel was registered by a controller driver */
@ -63,7 +63,7 @@ ide_channel_added(device_node_handle parent)
// which should be sufficient)
// Note: to fix specific drive bugs, use ide_sim_get_restrictions()
// in ide_sim.c!
{ BLKDEV_MAX_BLOCKS_ITEM, B_UINT32_TYPE, { ui32: 255 }},
{ B_BLOCK_DEVICE_MAX_BLOCKS_ITEM, B_UINT32_TYPE, { ui32: 255 }},
{ IDE_CHANNEL_ID_ITEM, B_UINT32_TYPE, { ui32: channel_id }},
{ PNP_MANAGER_ID_GENERATOR, B_STRING_TYPE, { string: IDE_CHANNEL_ID_GENERATOR }},
{ PNP_MANAGER_AUTO_ID, B_UINT32_TYPE, { ui32: channel_id }},

View File

@ -13,7 +13,7 @@
#define TRACE_PCI
#ifndef TRACE_PCI
# define TRACE(x) ;
# define TRACE(x)
#else
# define TRACE(x) dprintf x
#endif

View File

@ -18,7 +18,7 @@
#include <string.h>
#include <malloc.h>
#include <blkman.h>
#include <block_io.h>
// bus service should hurry up a bit - good controllers don't take much time
@ -197,15 +197,15 @@ scsi_init_bus(device_node_handle node, void *user_cookie, void **cookie)
return B_NO_MEMORY;
// extract controller/protocoll restrictions from node
if (pnp->get_attr_uint32(node, BLKDEV_DMA_ALIGNMENT, &bus->dma_params.alignment, true) != B_OK)
if (pnp->get_attr_uint32(node, B_BLOCK_DEVICE_DMA_ALIGNMENT, &bus->dma_params.alignment, true) != B_OK)
bus->dma_params.alignment = 0;
if (pnp->get_attr_uint32(node, BLKDEV_MAX_BLOCKS_ITEM, &bus->dma_params.max_blocks, true) != B_OK)
if (pnp->get_attr_uint32(node, B_BLOCK_DEVICE_MAX_BLOCKS_ITEM, &bus->dma_params.max_blocks, true) != B_OK)
bus->dma_params.max_blocks = 0xffffffff;
if (pnp->get_attr_uint32(node, BLKDEV_DMA_BOUNDARY, &bus->dma_params.dma_boundary, true) != B_OK)
if (pnp->get_attr_uint32(node, B_BLOCK_DEVICE_DMA_BOUNDARY, &bus->dma_params.dma_boundary, true) != B_OK)
bus->dma_params.dma_boundary = ~0;
if (pnp->get_attr_uint32(node, BLKDEV_MAX_SG_BLOCK_SIZE, &bus->dma_params.max_sg_block_size, true) != B_OK)
if (pnp->get_attr_uint32(node, B_BLOCK_DEVICE_MAX_SG_BLOCK_SIZE, &bus->dma_params.max_sg_block_size, true) != B_OK)
bus->dma_params.max_sg_block_size = 0xffffffff;
if (pnp->get_attr_uint32(node, BLKDEV_MAX_SG_BLOCKS, &bus->dma_params.max_sg_blocks, true) != B_OK)
if (pnp->get_attr_uint32(node, B_BLOCK_DEVICE_MAX_SG_BLOCKS, &bus->dma_params.max_sg_blocks, true) != B_OK)
bus->dma_params.max_sg_blocks = ~0;
// do some sanity check:

View File

@ -15,7 +15,7 @@
#include "scsi_internal.h"
#include <blkman.h>
#include <block_io.h>
#include <string.h>
#include <stdlib.h>
@ -121,7 +121,7 @@ scsi_register_device(scsi_bus_info *bus, uchar target_id,
// find maximum transfer blocks
// set default value to max (need something like ULONG_MAX here)
orig_max_blocks = ~0;
pnp->get_attr_uint32(bus->node, BLKDEV_MAX_BLOCKS_ITEM, &orig_max_blocks, true);
pnp->get_attr_uint32(bus->node, B_BLOCK_DEVICE_MAX_BLOCKS_ITEM, &orig_max_blocks, true);
max_blocks = min(max_blocks, orig_max_blocks);
@ -155,7 +155,7 @@ scsi_register_device(scsi_bus_info *bus, uchar target_id,
// ToDo: mapping is missing
// extra restriction of maximum number of blocks per transfer
{ BLKDEV_MAX_BLOCKS_ITEM, B_UINT32_TYPE, { ui32: max_blocks }},
{ B_BLOCK_DEVICE_MAX_BLOCKS_ITEM, B_UINT32_TYPE, { ui32: max_blocks }},
// atapi emulation
{ SCSI_DEVICE_IS_ATAPI_ITEM, B_UINT8_TYPE, { ui8: is_atapi }},

View File

@ -19,7 +19,7 @@
#include <bus/IDE.h>
#include <bus/ISA.h>
#include <device_manager.h>
#include <blkman.h>
#include <block_io.h>
#define debug_level_flow 0
#define debug_level_error 1
@ -344,7 +344,7 @@ publish_channel(device_node_handle parent, io_resource_handle *resources,
// DMA properties; the 16 bit alignment is not necessary as
// the ide bus manager handles that very efficiently, but why
// not use the block device manager for doing that?
{ BLKDEV_DMA_ALIGNMENT, B_UINT32_TYPE, { ui32: 1 }},
{ B_BLOCK_DEVICE_DMA_ALIGNMENT, B_UINT32_TYPE, { ui32: 1 }},
// private data to identify device
{ IDE_ISA_COMMAND_BLOCK_BASE, B_UINT16_TYPE, { ui16: command_block_base }},

View File

@ -18,7 +18,7 @@
#include <bus/ide/ide_adapter.h>
#include <bus/PCI.h>
#include <device_manager.h>
#include <blkman.h>
#include <block_io.h>
#include <lendian_bitfield.h>
#define debug_level_flow 0
@ -623,13 +623,13 @@ ide_adapter_publish_controller(device_node_handle parent, uint16 bus_master_base
// DMA properties
// data must be word-aligned;
// warning: some controllers are more picky!
{ BLKDEV_DMA_ALIGNMENT, B_UINT32_TYPE, { ui32: dma_alignment /*1*/}},
{ B_BLOCK_DEVICE_DMA_ALIGNMENT, B_UINT32_TYPE, { ui32: dma_alignment /*1*/}},
// one S/G block must not cross 64K boundary
{ BLKDEV_DMA_BOUNDARY, B_UINT32_TYPE, { ui32: dma_boundary/*0xffff*/ }},
{ B_BLOCK_DEVICE_DMA_BOUNDARY, B_UINT32_TYPE, { ui32: dma_boundary/*0xffff*/ }},
// max size of S/G block is 16 bits with zero being 64K
{ BLKDEV_MAX_SG_BLOCK_SIZE, B_UINT32_TYPE, { ui32: max_sg_block_size/*0x10000*/ }},
{ B_BLOCK_DEVICE_MAX_SG_BLOCK_SIZE, B_UINT32_TYPE, { ui32: max_sg_block_size/*0x10000*/ }},
// see definition of MAX_SG_COUNT
{ BLKDEV_MAX_SG_BLOCKS, B_UINT32_TYPE, { ui32: IDE_ADAPTER_MAX_SG_COUNT }},
{ B_BLOCK_DEVICE_MAX_SG_BLOCKS, B_UINT32_TYPE, { ui32: IDE_ADAPTER_MAX_SG_COUNT }},
// private data to find controller
{ IDE_ADAPTER_BUS_MASTER_BASE, B_UINT16_TYPE, { ui16: bus_master_base }},