From 861646f52217cf42a0e2e6558d85bd1172ca1611 Mon Sep 17 00:00:00 2001 From: Stefan Richter Date: Mon, 20 Nov 2006 00:07:26 +0100 Subject: ieee1394: dv1394: schedule for feature removal Signed-off-by: Stefan Richter --- drivers/ieee1394/Kconfig | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) (limited to 'drivers/ieee1394/Kconfig') diff --git a/drivers/ieee1394/Kconfig b/drivers/ieee1394/Kconfig index 672b92ef9f21..680da9e195dc 100644 --- a/drivers/ieee1394/Kconfig +++ b/drivers/ieee1394/Kconfig @@ -161,17 +161,12 @@ config IEEE1394_ETH1394 MCAP, therefore multicast support is significantly limited. config IEEE1394_DV1394 - tristate "OHCI-DV I/O support" + tristate "OHCI-DV I/O support (deprecated)" depends on IEEE1394 && IEEE1394_OHCI1394 help - This driver allows you to transmit and receive DV (digital video) - streams on an OHCI-1394 card using a simple frame-oriented - interface. - - The user-space API for dv1394 is documented in dv1394.h. - - To compile this driver as a module, say M here: the - module will be called dv1394. + The dv1394 driver will be removed from Linux in a future release. + Its functionality is now provided by raw1394 together with libraries + such as libiec61883. config IEEE1394_RAWIO tristate "Raw IEEE1394 I/O support" -- cgit v1.2.3 From e9429dfdc34402de3832ab7335f8ff0104f3ae84 Mon Sep 17 00:00:00 2001 From: Stefan Richter Date: Sun, 19 Nov 2006 23:03:09 +0100 Subject: ieee1394: schedule unused symbol exports for removal This also means that former parts of ieee1394's API will be subject to change or removal. Signed-off-by: Stefan Richter --- Documentation/feature-removal-schedule.txt | 7 +++++++ drivers/ieee1394/Kconfig | 9 ++------- 2 files changed, 9 insertions(+), 7 deletions(-) (limited to 'drivers/ieee1394/Kconfig') diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt index c8c6daeefed0..ed10a464e915 100644 --- a/Documentation/feature-removal-schedule.txt +++ b/Documentation/feature-removal-schedule.txt @@ -50,6 +50,13 @@ Who: Dan Dennedy , Stefan Richter --------------------------- +What: ieee1394 core's unused exports (CONFIG_IEEE1394_EXPORT_FULL_API) +When: January 2007 +Why: There are no projects known to use these exported symbols. +Who: Stefan Richter + +--------------------------- + What: Video4Linux API 1 ioctls and video_decoder.h from Video devices. When: December 2006 Why: V4L1 AP1 was replaced by V4L2 API. during migration from 2.4 to 2.6 diff --git a/drivers/ieee1394/Kconfig b/drivers/ieee1394/Kconfig index 680da9e195dc..87325ddbda56 100644 --- a/drivers/ieee1394/Kconfig +++ b/drivers/ieee1394/Kconfig @@ -67,16 +67,11 @@ config IEEE1394_CONFIG_ROM_IP1394 eth1394 option below. config IEEE1394_EXPORT_FULL_API - bool "Export all symbols of ieee1394's API" + bool "Export all symbols of ieee1394's API (deprecated)" depends on IEEE1394 default n help - Export all symbols of ieee1394's driver programming interface, even - those that are not currently used by the standard IEEE 1394 drivers. - - This option does not affect the interface to userspace applications. - Say Y here if you want to compile externally developed drivers that - make extended use of ieee1394's API. It is otherwise safe to say N. + This option will be removed soon. Don't worry, say N. comment "Device Drivers" depends on IEEE1394 -- cgit v1.2.3 From 4e834da1da2d7e80547e493c4b21c809dcb0ae09 Mon Sep 17 00:00:00 2001 From: Stefan Richter Date: Sun, 19 Nov 2006 23:04:31 +0100 Subject: ieee1394: schedule *_oui sysfs attributes for removal There is no manpower available to reform oui.db into a library for use in more kernel subsystems. The low ratio of usefulness to size and the occasional need to update oui.db from IEEE's official list suggest to drop oui.db. I plan to make a userspace script available which translates the remaining numeric sysfs attributes to names of organizations. Signed-off-by: Stefan Richter --- Documentation/feature-removal-schedule.txt | 8 ++++++++ drivers/ieee1394/Kconfig | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) (limited to 'drivers/ieee1394/Kconfig') diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt index ed10a464e915..3d5ffd0041bd 100644 --- a/Documentation/feature-removal-schedule.txt +++ b/Documentation/feature-removal-schedule.txt @@ -57,6 +57,14 @@ Who: Stefan Richter --------------------------- +What: ieee1394's *_oui sysfs attributes (CONFIG_IEEE1394_OUI_DB) +When: January 2007 +Files: drivers/ieee1394/: oui.db, oui2c.sh +Why: big size, little value +Who: Stefan Richter + +--------------------------- + What: Video4Linux API 1 ioctls and video_decoder.h from Video devices. When: December 2006 Why: V4L1 AP1 was replaced by V4L2 API. during migration from 2.4 to 2.6 diff --git a/drivers/ieee1394/Kconfig b/drivers/ieee1394/Kconfig index 87325ddbda56..21a13348f258 100644 --- a/drivers/ieee1394/Kconfig +++ b/drivers/ieee1394/Kconfig @@ -36,7 +36,7 @@ config IEEE1394_VERBOSEDEBUG else says N. config IEEE1394_OUI_DB - bool "OUI Database built-in" + bool "OUI Database built-in (deprecated)" depends on IEEE1394 help If you say Y here, then an OUI list (vendor unique ID's) will be -- cgit v1.2.3 From 9b7d9c096dd4e4baacc21b2588662bbb56f36c4e Mon Sep 17 00:00:00 2001 From: Stefan Richter Date: Wed, 22 Nov 2006 21:44:34 +0100 Subject: ieee1394: sbp2: convert from PCI DMA to generic DMA API conversion without change in functionality Signed-off-by: Stefan Richter --- drivers/ieee1394/Kconfig | 2 +- drivers/ieee1394/sbp2.c | 126 ++++++++++++++++++++++------------------------- drivers/ieee1394/sbp2.h | 2 +- 3 files changed, 62 insertions(+), 68 deletions(-) (limited to 'drivers/ieee1394/Kconfig') diff --git a/drivers/ieee1394/Kconfig b/drivers/ieee1394/Kconfig index 21a13348f258..e7d56573fe56 100644 --- a/drivers/ieee1394/Kconfig +++ b/drivers/ieee1394/Kconfig @@ -120,7 +120,7 @@ comment "SBP-2 support (for storage devices) requires SCSI" config IEEE1394_SBP2 tristate "SBP-2 support (Harddisks etc.)" - depends on IEEE1394 && SCSI && (PCI || BROKEN) + depends on IEEE1394 && SCSI help This option enables you to use SBP-2 devices connected to an IEEE 1394 bus. SBP-2 devices include storage devices like harddisks and diff --git a/drivers/ieee1394/sbp2.c b/drivers/ieee1394/sbp2.c index 5d3b96e0a951..ab7059858bbd 100644 --- a/drivers/ieee1394/sbp2.c +++ b/drivers/ieee1394/sbp2.c @@ -48,7 +48,6 @@ * - make the parameter serialize_io configurable per device * - move all requests to fetch agent registers into non-atomic context, * replace all usages of sbp2util_node_write_no_wait by true transactions - * - convert to generic DMA mapping API to eliminate dependency on PCI * Grep for inline FIXME comments below. */ @@ -63,7 +62,6 @@ #include #include #include -#include #include #include #include @@ -491,14 +489,14 @@ static int sbp2util_create_command_orb_pool(struct sbp2_lu *lu) spin_unlock_irqrestore(&lu->cmd_orb_lock, flags); return -ENOMEM; } - cmd->command_orb_dma = pci_map_single(hi->host->pdev, + cmd->command_orb_dma = dma_map_single(&hi->host->device, &cmd->command_orb, sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); - cmd->sge_dma = pci_map_single(hi->host->pdev, + DMA_TO_DEVICE); + cmd->sge_dma = dma_map_single(&hi->host->device, &cmd->scatter_gather_element, sizeof(cmd->scatter_gather_element), - PCI_DMA_BIDIRECTIONAL); + DMA_BIDIRECTIONAL); INIT_LIST_HEAD(&cmd->list); list_add_tail(&cmd->list, &lu->cmd_orb_completed); } @@ -517,12 +515,12 @@ static void sbp2util_remove_command_orb_pool(struct sbp2_lu *lu) if (!list_empty(&lu->cmd_orb_completed)) list_for_each_safe(lh, next, &lu->cmd_orb_completed) { cmd = list_entry(lh, struct sbp2_command_info, list); - pci_unmap_single(host->pdev, cmd->command_orb_dma, + dma_unmap_single(&host->device, cmd->command_orb_dma, sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); - pci_unmap_single(host->pdev, cmd->sge_dma, + DMA_TO_DEVICE); + dma_unmap_single(&host->device, cmd->sge_dma, sizeof(cmd->scatter_gather_element), - PCI_DMA_BIDIRECTIONAL); + DMA_BIDIRECTIONAL); kfree(cmd); } spin_unlock_irqrestore(&lu->cmd_orb_lock, flags); @@ -602,17 +600,17 @@ static void sbp2util_mark_command_completed(struct sbp2_lu *lu, if (cmd->cmd_dma) { if (cmd->dma_type == CMD_DMA_SINGLE) - pci_unmap_single(host->pdev, cmd->cmd_dma, + dma_unmap_single(&host->device, cmd->cmd_dma, cmd->dma_size, cmd->dma_dir); else if (cmd->dma_type == CMD_DMA_PAGE) - pci_unmap_page(host->pdev, cmd->cmd_dma, + dma_unmap_page(&host->device, cmd->cmd_dma, cmd->dma_size, cmd->dma_dir); /* XXX: Check for CMD_DMA_NONE bug */ cmd->dma_type = CMD_DMA_NONE; cmd->cmd_dma = 0; } if (cmd->sge_buffer) { - pci_unmap_sg(host->pdev, cmd->sge_buffer, + dma_unmap_sg(&host->device, cmd->sge_buffer, cmd->dma_size, cmd->dma_dir); cmd->sge_buffer = NULL; } @@ -837,39 +835,39 @@ static int sbp2_start_device(struct sbp2_lu *lu) struct sbp2_fwhost_info *hi = lu->hi; int error; - lu->login_response = pci_alloc_consistent(hi->host->pdev, + lu->login_response = dma_alloc_coherent(&hi->host->device, sizeof(struct sbp2_login_response), - &lu->login_response_dma); + &lu->login_response_dma, GFP_KERNEL); if (!lu->login_response) goto alloc_fail; - lu->query_logins_orb = pci_alloc_consistent(hi->host->pdev, + lu->query_logins_orb = dma_alloc_coherent(&hi->host->device, sizeof(struct sbp2_query_logins_orb), - &lu->query_logins_orb_dma); + &lu->query_logins_orb_dma, GFP_KERNEL); if (!lu->query_logins_orb) goto alloc_fail; - lu->query_logins_response = pci_alloc_consistent(hi->host->pdev, + lu->query_logins_response = dma_alloc_coherent(&hi->host->device, sizeof(struct sbp2_query_logins_response), - &lu->query_logins_response_dma); + &lu->query_logins_response_dma, GFP_KERNEL); if (!lu->query_logins_response) goto alloc_fail; - lu->reconnect_orb = pci_alloc_consistent(hi->host->pdev, + lu->reconnect_orb = dma_alloc_coherent(&hi->host->device, sizeof(struct sbp2_reconnect_orb), - &lu->reconnect_orb_dma); + &lu->reconnect_orb_dma, GFP_KERNEL); if (!lu->reconnect_orb) goto alloc_fail; - lu->logout_orb = pci_alloc_consistent(hi->host->pdev, + lu->logout_orb = dma_alloc_coherent(&hi->host->device, sizeof(struct sbp2_logout_orb), - &lu->logout_orb_dma); + &lu->logout_orb_dma, GFP_KERNEL); if (!lu->logout_orb) goto alloc_fail; - lu->login_orb = pci_alloc_consistent(hi->host->pdev, + lu->login_orb = dma_alloc_coherent(&hi->host->device, sizeof(struct sbp2_login_orb), - &lu->login_orb_dma); + &lu->login_orb_dma, GFP_KERNEL); if (!lu->login_orb) goto alloc_fail; @@ -930,32 +928,32 @@ static void sbp2_remove_device(struct sbp2_lu *lu) list_del(&lu->lu_list); if (lu->login_response) - pci_free_consistent(hi->host->pdev, + dma_free_coherent(&hi->host->device, sizeof(struct sbp2_login_response), lu->login_response, lu->login_response_dma); if (lu->login_orb) - pci_free_consistent(hi->host->pdev, + dma_free_coherent(&hi->host->device, sizeof(struct sbp2_login_orb), lu->login_orb, lu->login_orb_dma); if (lu->reconnect_orb) - pci_free_consistent(hi->host->pdev, + dma_free_coherent(&hi->host->device, sizeof(struct sbp2_reconnect_orb), lu->reconnect_orb, lu->reconnect_orb_dma); if (lu->logout_orb) - pci_free_consistent(hi->host->pdev, + dma_free_coherent(&hi->host->device, sizeof(struct sbp2_logout_orb), lu->logout_orb, lu->logout_orb_dma); if (lu->query_logins_orb) - pci_free_consistent(hi->host->pdev, + dma_free_coherent(&hi->host->device, sizeof(struct sbp2_query_logins_orb), lu->query_logins_orb, lu->query_logins_orb_dma); if (lu->query_logins_response) - pci_free_consistent(hi->host->pdev, + dma_free_coherent(&hi->host->device, sizeof(struct sbp2_query_logins_response), lu->query_logins_response, lu->query_logins_response_dma); @@ -1446,7 +1444,7 @@ static void sbp2_prep_command_orb_sg(struct sbp2_command_orb *orb, cmd->dma_size = sgpnt[0].length; cmd->dma_type = CMD_DMA_PAGE; - cmd->cmd_dma = pci_map_page(hi->host->pdev, + cmd->cmd_dma = dma_map_page(&hi->host->device, sgpnt[0].page, sgpnt[0].offset, cmd->dma_size, cmd->dma_dir); @@ -1458,7 +1456,7 @@ static void sbp2_prep_command_orb_sg(struct sbp2_command_orb *orb, &cmd->scatter_gather_element[0]; u32 sg_count, sg_len; dma_addr_t sg_addr; - int i, count = pci_map_sg(hi->host->pdev, sgpnt, scsi_use_sg, + int i, count = dma_map_sg(&hi->host->device, sgpnt, scsi_use_sg, dma_dir); cmd->dma_size = scsi_use_sg; @@ -1509,7 +1507,7 @@ static void sbp2_prep_command_orb_no_sg(struct sbp2_command_orb *orb, cmd->dma_dir = dma_dir; cmd->dma_size = scsi_request_bufflen; cmd->dma_type = CMD_DMA_SINGLE; - cmd->cmd_dma = pci_map_single(hi->host->pdev, scsi_request_buffer, + cmd->cmd_dma = dma_map_single(&hi->host->device, scsi_request_buffer, cmd->dma_size, cmd->dma_dir); orb->data_descriptor_hi = ORB_SET_NODE_ID(hi->host->node_id); orb->misc |= ORB_SET_DIRECTION(orb_direction); @@ -1627,12 +1625,12 @@ static void sbp2_link_orb_command(struct sbp2_lu *lu, size_t length; unsigned long flags; - pci_dma_sync_single_for_device(hi->host->pdev, cmd->command_orb_dma, - sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); - pci_dma_sync_single_for_device(hi->host->pdev, cmd->sge_dma, - sizeof(cmd->scatter_gather_element), - PCI_DMA_BIDIRECTIONAL); + dma_sync_single_for_device(&hi->host->device, cmd->command_orb_dma, + sizeof(struct sbp2_command_orb), + DMA_TO_DEVICE); + dma_sync_single_for_device(&hi->host->device, cmd->sge_dma, + sizeof(cmd->scatter_gather_element), + DMA_BIDIRECTIONAL); /* check to see if there are any previous orbs to use */ spin_lock_irqsave(&lu->cmd_orb_lock, flags); @@ -1656,16 +1654,16 @@ static void sbp2_link_orb_command(struct sbp2_lu *lu, * The target's fetch agent may or may not have read this * previous ORB yet. */ - pci_dma_sync_single_for_cpu(hi->host->pdev, last_orb_dma, - sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); + dma_sync_single_for_cpu(&hi->host->device, last_orb_dma, + sizeof(struct sbp2_command_orb), + DMA_TO_DEVICE); last_orb->next_ORB_lo = cpu_to_be32(cmd->command_orb_dma); wmb(); /* Tells hardware that this pointer is valid */ last_orb->next_ORB_hi = 0; - pci_dma_sync_single_for_device(hi->host->pdev, last_orb_dma, - sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); + dma_sync_single_for_device(&hi->host->device, last_orb_dma, + sizeof(struct sbp2_command_orb), + DMA_TO_DEVICE); addr += SBP2_DOORBELL_OFFSET; data[0] = 0; length = 4; @@ -1792,14 +1790,12 @@ static int sbp2_handle_status_write(struct hpsb_host *host, int nodeid, else cmd = sbp2util_find_command_for_orb(lu, sb->ORB_offset_lo); if (cmd) { - pci_dma_sync_single_for_cpu(hi->host->pdev, - cmd->command_orb_dma, - sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); - pci_dma_sync_single_for_cpu(hi->host->pdev, - cmd->sge_dma, - sizeof(cmd->scatter_gather_element), - PCI_DMA_BIDIRECTIONAL); + dma_sync_single_for_cpu(&hi->host->device, cmd->command_orb_dma, + sizeof(struct sbp2_command_orb), + DMA_TO_DEVICE); + dma_sync_single_for_cpu(&hi->host->device, cmd->sge_dma, + sizeof(cmd->scatter_gather_element), + DMA_BIDIRECTIONAL); /* Grab SCSI command pointers and check status. */ /* * FIXME: If the src field in the status is 1, the ORB DMA must @@ -1935,13 +1931,12 @@ static void sbp2scsi_complete_all_commands(struct sbp2_lu *lu, u32 status) while (!list_empty(&lu->cmd_orb_inuse)) { lh = lu->cmd_orb_inuse.next; cmd = list_entry(lh, struct sbp2_command_info, list); - pci_dma_sync_single_for_cpu(hi->host->pdev, - cmd->command_orb_dma, - sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); - pci_dma_sync_single_for_cpu(hi->host->pdev, cmd->sge_dma, - sizeof(cmd->scatter_gather_element), - PCI_DMA_BIDIRECTIONAL); + dma_sync_single_for_cpu(&hi->host->device, cmd->command_orb_dma, + sizeof(struct sbp2_command_orb), + DMA_TO_DEVICE); + dma_sync_single_for_cpu(&hi->host->device, cmd->sge_dma, + sizeof(cmd->scatter_gather_element), + DMA_BIDIRECTIONAL); sbp2util_mark_command_completed(lu, cmd); if (cmd->Current_SCpnt) { cmd->Current_SCpnt->result = status << 16; @@ -2064,14 +2059,13 @@ static int sbp2scsi_abort(struct scsi_cmnd *SCpnt) spin_lock_irqsave(&lu->cmd_orb_lock, flags); cmd = sbp2util_find_command_for_SCpnt(lu, SCpnt); if (cmd) { - pci_dma_sync_single_for_cpu(hi->host->pdev, + dma_sync_single_for_cpu(&hi->host->device, cmd->command_orb_dma, sizeof(struct sbp2_command_orb), - PCI_DMA_TODEVICE); - pci_dma_sync_single_for_cpu(hi->host->pdev, - cmd->sge_dma, + DMA_TO_DEVICE); + dma_sync_single_for_cpu(&hi->host->device, cmd->sge_dma, sizeof(cmd->scatter_gather_element), - PCI_DMA_BIDIRECTIONAL); + DMA_BIDIRECTIONAL); sbp2util_mark_command_completed(lu, cmd); if (cmd->Current_SCpnt) { cmd->Current_SCpnt->result = DID_ABORT << 16; diff --git a/drivers/ieee1394/sbp2.h b/drivers/ieee1394/sbp2.h index ef24d630a577..9ae842329bf3 100644 --- a/drivers/ieee1394/sbp2.h +++ b/drivers/ieee1394/sbp2.h @@ -263,7 +263,7 @@ struct sbp2_command_info { dma_addr_t cmd_dma; enum sbp2_dma_types dma_type; unsigned long dma_size; - int dma_dir; + enum dma_data_direction dma_dir; }; /* Per FireWire host */ -- cgit v1.2.3