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:
+3
-3
@@ -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 \
|
BEOS_ADD_ONS_DRIVERS_NET="ipro1000 rtl8139 rtl8169 sis900 \
|
||||||
via-rhine wb840 net_stack_driver" # bcm440x bcm570x (only available with GPLd add-ons)
|
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_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"
|
scsi_periph intel keyboard vga_text"
|
||||||
BEOS_ADD_ONS_FILESYSTEMS="bfs"
|
BEOS_ADD_ONS_FILESYSTEMS="bfs"
|
||||||
BEOS_DATA_FILES="timezone_files keymap_files"
|
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
|
$cp ${sPrefix}bus_managers/$f $targetDir/beos/system/add-ons/kernel/bus_managers/$f
|
||||||
done
|
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 \
|
generic/ide_adapter generic/locked_pool generic/scsi_periph \
|
||||||
partitioning_systems/intel console/vga_text busses/ide/generic_ide_pci; do
|
partitioning_systems/intel console/vga_text busses/ide/generic_ide_pci; do
|
||||||
$cp ${sPrefix}$f $targetDir/beos/system/add-ons/kernel/$f
|
$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..."
|
echo "Creating boot module links..."
|
||||||
$cd $targetDir/beos/system/add-ons/kernel/boot
|
$cd $targetDir/beos/system/add-ons/kernel/boot
|
||||||
for f in bus_managers/config_manager bus_managers/pci bus_managers/isa bus_managers/ide \
|
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 \
|
generic/fast_log generic/ide_adapter generic/locked_pool generic/scsi_periph \
|
||||||
partitioning_systems/intel busses/ide/generic_ide_pci; do
|
partitioning_systems/intel busses/ide/generic_ide_pci; do
|
||||||
$ln -fs /boot/beos/system/add-ons/kernel/$f $(basename $f)
|
$ln -fs /boot/beos/system/add-ons/kernel/$f $(basename $f)
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <malloc.h>
|
#include <malloc.h>
|
||||||
|
|
||||||
#include <blkman.h>
|
#include <block_io.h>
|
||||||
|
|
||||||
|
|
||||||
/** called when an IDE channel was registered by a controller driver */
|
/** 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)
|
// which should be sufficient)
|
||||||
// Note: to fix specific drive bugs, use ide_sim_get_restrictions()
|
// Note: to fix specific drive bugs, use ide_sim_get_restrictions()
|
||||||
// in ide_sim.c!
|
// 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 }},
|
{ IDE_CHANNEL_ID_ITEM, B_UINT32_TYPE, { ui32: channel_id }},
|
||||||
{ PNP_MANAGER_ID_GENERATOR, B_STRING_TYPE, { string: IDE_CHANNEL_ID_GENERATOR }},
|
{ PNP_MANAGER_ID_GENERATOR, B_STRING_TYPE, { string: IDE_CHANNEL_ID_GENERATOR }},
|
||||||
{ PNP_MANAGER_AUTO_ID, B_UINT32_TYPE, { ui32: channel_id }},
|
{ PNP_MANAGER_AUTO_ID, B_UINT32_TYPE, { ui32: channel_id }},
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
#define TRACE_PCI
|
#define TRACE_PCI
|
||||||
#ifndef TRACE_PCI
|
#ifndef TRACE_PCI
|
||||||
# define TRACE(x) ;
|
# define TRACE(x)
|
||||||
#else
|
#else
|
||||||
# define TRACE(x) dprintf x
|
# define TRACE(x) dprintf x
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <malloc.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
|
// 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;
|
return B_NO_MEMORY;
|
||||||
|
|
||||||
// extract controller/protocoll restrictions from node
|
// 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;
|
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;
|
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;
|
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;
|
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;
|
bus->dma_params.max_sg_blocks = ~0;
|
||||||
|
|
||||||
// do some sanity check:
|
// do some sanity check:
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
#include "scsi_internal.h"
|
#include "scsi_internal.h"
|
||||||
|
|
||||||
#include <blkman.h>
|
#include <block_io.h>
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
@@ -121,7 +121,7 @@ scsi_register_device(scsi_bus_info *bus, uchar target_id,
|
|||||||
// find maximum transfer blocks
|
// find maximum transfer blocks
|
||||||
// set default value to max (need something like ULONG_MAX here)
|
// set default value to max (need something like ULONG_MAX here)
|
||||||
orig_max_blocks = ~0;
|
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);
|
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
|
// ToDo: mapping is missing
|
||||||
|
|
||||||
// extra restriction of maximum number of blocks per transfer
|
// 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
|
// atapi emulation
|
||||||
{ SCSI_DEVICE_IS_ATAPI_ITEM, B_UINT8_TYPE, { ui8: is_atapi }},
|
{ SCSI_DEVICE_IS_ATAPI_ITEM, B_UINT8_TYPE, { ui8: is_atapi }},
|
||||||
|
|||||||
@@ -19,7 +19,7 @@
|
|||||||
#include <bus/IDE.h>
|
#include <bus/IDE.h>
|
||||||
#include <bus/ISA.h>
|
#include <bus/ISA.h>
|
||||||
#include <device_manager.h>
|
#include <device_manager.h>
|
||||||
#include <blkman.h>
|
#include <block_io.h>
|
||||||
|
|
||||||
#define debug_level_flow 0
|
#define debug_level_flow 0
|
||||||
#define debug_level_error 1
|
#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
|
// DMA properties; the 16 bit alignment is not necessary as
|
||||||
// the ide bus manager handles that very efficiently, but why
|
// the ide bus manager handles that very efficiently, but why
|
||||||
// not use the block device manager for doing that?
|
// 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
|
// private data to identify device
|
||||||
{ IDE_ISA_COMMAND_BLOCK_BASE, B_UINT16_TYPE, { ui16: command_block_base }},
|
{ IDE_ISA_COMMAND_BLOCK_BASE, B_UINT16_TYPE, { ui16: command_block_base }},
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
#include <bus/ide/ide_adapter.h>
|
#include <bus/ide/ide_adapter.h>
|
||||||
#include <bus/PCI.h>
|
#include <bus/PCI.h>
|
||||||
#include <device_manager.h>
|
#include <device_manager.h>
|
||||||
#include <blkman.h>
|
#include <block_io.h>
|
||||||
#include <lendian_bitfield.h>
|
#include <lendian_bitfield.h>
|
||||||
|
|
||||||
#define debug_level_flow 0
|
#define debug_level_flow 0
|
||||||
@@ -623,13 +623,13 @@ ide_adapter_publish_controller(device_node_handle parent, uint16 bus_master_base
|
|||||||
// DMA properties
|
// DMA properties
|
||||||
// data must be word-aligned;
|
// data must be word-aligned;
|
||||||
// warning: some controllers are more picky!
|
// 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
|
// 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
|
// 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
|
// 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
|
// private data to find controller
|
||||||
{ IDE_ADAPTER_BUS_MASTER_BASE, B_UINT16_TYPE, { ui16: bus_master_base }},
|
{ IDE_ADAPTER_BUS_MASTER_BASE, B_UINT16_TYPE, { ui16: bus_master_base }},
|
||||||
|
|||||||
Reference in New Issue
Block a user