the scheduled removal of RAW1394_REQ_ISO_{SEND,LISTEN}
PATCH 1/1 the scheduled removal of RAW1394_REQ_ISO_{SEND,LISTEN}
This patch contains the scheduled removal of requests of type RAW1394_REQ_ISO_SEND, RAW1394_REQ_ISO_LISTEN.
---
Documentation/feature-removal-schedule.txt | 9 - drivers/ieee1394/highlevel.c | 37 ---- drivers/ieee1394/highlevel.h | 21 -- drivers/ieee1394/hosts.h | 2 drivers/ieee1394/ieee1394_core.c | 7 drivers/ieee1394/ieee1394_transactions.c | 30 ---- drivers/ieee1394/ieee1394_transactions.h | 2 drivers/ieee1394/raw1394-private.h | 5 drivers/ieee1394/raw1394.c | 157 --------------------- drivers/ieee1394/raw1394.h | 4 10 files changed, 3 insertions(+), 271 deletions(-)
Documentation/feature-removal-schedule.txt renamed from Documentation/feature-removal-schedule.txt.old +0 -9
@@ -29,15 +29,6 @@ Who: Adrian Bunk <[email protected]> --------------------------- -What: raw1394: requests of type RAW1394_REQ_ISO_SEND, RAW1394_REQ_ISO_LISTEN -When: November 2006 -Why: Deprecated in favour of the new ioctl-based rawiso interface, which is - more efficient. You should really be using libraw1394 for raw1394 - access anyway. -Who: Jody McIntyre <[email protected]> - ---------------------------- - 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
drivers/ieee1394/raw1394.h renamed from drivers/ieee1394/raw1394.h.old +2 -2
@@ -17,11 +17,11 @@#define RAW1394_REQ_ASYNC_WRITE 101#define RAW1394_REQ_LOCK 102#define RAW1394_REQ_LOCK64 103 -#define RAW1394_REQ_ISO_SEND 104 +/* removed: RAW1394_REQ_ISO_SEND 104 */ #define RAW1394_REQ_ASYNC_SEND 105#define RAW1394_REQ_ASYNC_STREAM 106 -#define RAW1394_REQ_ISO_LISTEN 200 +/* removed: RAW1394_REQ_ISO_LISTEN 200 */ #define RAW1394_REQ_FCP_LISTEN 201#define RAW1394_REQ_RESET_BUS 202#define RAW1394_REQ_GET_ROM 203
drivers/ieee1394/raw1394.c renamed from drivers/ieee1394/raw1394.c.old +0 -157
200 lines not on this page · raw message
drivers/ieee1394/highlevel.h renamed from drivers/ieee1394/highlevel.h.old +1 -20
@@ -26,9 +26,7 @@ struct hpsb_address_serve {struct hpsb_highlevel {const char *name; -/* Any of the following pointers can legally be NULL, except for -* iso_receive which can only be NULL when you don't request -* channels. */ +/* Any of the following pointers can legally be NULL. */ /* New host initialized. Will also be called during * hpsb_register_highlevel for all hosts already installed. */
@@ -43,13 +41,6 @@ struct hpsb_highlevel {* You can not expect to be able to do stock hpsb_reads. */ void (*host_reset)(struct hpsb_host *host); -/* An isochronous packet was received. Channel contains the channel -* number for your convenience, it is also contained in the included -* packet header (first quadlet, CRCs are missing). You may get called -* for channel/host combinations you did not request. */ -void (*iso_receive)(struct hpsb_host *host,int channel, -quadlet_t *data,size_t length); -/* A write request was received on either the FCP_COMMAND (direction = * 0) or the FCP_RESPONSE (direction = 1) register. The cts arg * contains the cts field (first byte of data). */
@@ -120,7 +111,6 @@ int highlevel_lock64(struct hpsb_host *h u64 addr, octlet_t data, octlet_t arg, int ext_tcode, u16 flags); -void highlevel_iso_receive (struct hpsb_host *host,void *data,size_t length);void highlevel_fcp_request (struct hpsb_host *host,int nodeid,int direction,void *data,size_t length);
@@ -153,15 +143,6 @@ int hpsb_register_addrspace(struct hpsb_int hpsb_unregister_addrspace (struct hpsb_highlevel *hl,struct hpsb_host *host,u64 start); -/* -* Enable or disable receving a certain isochronous channel through the -* iso_receive op. -*/ -int hpsb_listen_channel (struct hpsb_highlevel *hl,struct hpsb_host *host, -unsigned int channel); -void hpsb_unlisten_channel (struct hpsb_highlevel *hl,struct hpsb_host *host, -unsigned int channel); -/* Retrieve a hostinfo pointer bound to this driver/host */ void *hpsb_get_hostinfo (struct hpsb_highlevel *hl,struct hpsb_host *host);
drivers/ieee1394/highlevel.c renamed from drivers/ieee1394/highlevel.c.old +0 -37
@@ -419,29 +419,6 @@ int hpsb_unregister_addrspace(struct hpsreturn retval; } -int hpsb_listen_channel (struct hpsb_highlevel *hl,struct hpsb_host *host, -unsigned int channel) -{ -if (channel >63 ) { -HPSB_ERR ("%s called with invalid channel" , __FUNCTION__); -return -EINVAL ; - } -if (host->iso_listen_count[channel]++ ==0 ) -return host->driver->devctl (host,ISO_LISTEN_CHANNEL , channel); -return 0 ; -} - -void hpsb_unlisten_channel (struct hpsb_highlevel *hl,struct hpsb_host *host, -unsigned int channel) -{ -if (channel >63 ) { -HPSB_ERR ("%s called with invalid channel" , __FUNCTION__); -return ; - } -if (--host->iso_listen_count[channel] ==0 ) - host->driver->devctl (host,ISO_UNLISTEN_CHANNEL , channel); -} -static void init_hpsb_highlevel (struct hpsb_host *host) {INIT_LIST_HEAD (&dummy_zero_addr.host_list);
@@ -498,20 +475,6 @@ void highlevel_host_reset(struct hpsb_horead_unlock_irqrestore (&hl_irqs_lock, flags); } -void highlevel_iso_receive (struct hpsb_host *host,void *data,size_t length) -{ -unsigned long flags; -struct hpsb_highlevel *hl; -int channel = (((quadlet_t *)data)[0 ] >>8 ) &0x3f ; - -read_lock_irqsave (&hl_irqs_lock, flags); -list_for_each_entry (hl, &hl_irqs, irq_list) { -if (hl->iso_receive) - hl->iso_receive (host, channel, data, length); - } -read_unlock_irqrestore (&hl_irqs_lock, flags); -} -void highlevel_fcp_request (struct hpsb_host *host,int nodeid,int direction,void *data,size_t length) {
drivers/ieee1394/ieee1394_core.c renamed from drivers/ieee1394/ieee1394_core.c.old +0 -7
@@ -925,10 +925,6 @@ void hpsb_packet_received(struct hpsb_hobreak ; -case TCODE_ISO_DATA : -highlevel_iso_receive (host, data, size); -break ; -case TCODE_CYCLE_START :/* simply ignore this packet if it is passed on */ break ;
@@ -1209,7 +1205,6 @@ EXPORT_SYMBOL(hpsb_make_streampacket);EXPORT_SYMBOL (hpsb_make_lockpacket);EXPORT_SYMBOL (hpsb_make_lock64packet);EXPORT_SYMBOL (hpsb_make_phypacket); -EXPORT_SYMBOL (hpsb_make_isopacket);EXPORT_SYMBOL (hpsb_read);EXPORT_SYMBOL (hpsb_write);EXPORT_SYMBOL (hpsb_packet_success);
@@ -1220,8 +1215,6 @@ EXPORT_SYMBOL(hpsb_unregister_highlevel)EXPORT_SYMBOL (hpsb_register_addrspace);EXPORT_SYMBOL (hpsb_unregister_addrspace);EXPORT_SYMBOL (hpsb_allocate_and_register_addrspace); -EXPORT_SYMBOL (hpsb_listen_channel); -EXPORT_SYMBOL (hpsb_unlisten_channel);EXPORT_SYMBOL (hpsb_get_hostinfo);EXPORT_SYMBOL (hpsb_create_hostinfo);EXPORT_SYMBOL (hpsb_destroy_hostinfo);
drivers/ieee1394/ieee1394_transactions.h renamed from drivers/ieee1394/ieee1394_transactions.h.old +0 -2
@@ -19,8 +19,6 @@ struct hpsb_packet *hpsb_make_lock64pack nodeid_t node, u64 addr, int extcode, octlet_t *data, octlet_t arg);struct hpsb_packet *hpsb_make_phypacket (struct hpsb_host *host,quadlet_t data); -struct hpsb_packet *hpsb_make_isopacket (struct hpsb_host *host,int length, -int channel,int tag,int sync);struct hpsb_packet *hpsb_make_writepacket (struct hpsb_host *host,nodeid_t node,u64 addr,quadlet_t *buffer,size_t length);
drivers/ieee1394/ieee1394_transactions.c renamed from drivers/ieee1394/ieee1394_transactions.c.old +0 -30
@@ -84,18 +84,6 @@ static void fill_async_lock(struct hpsb_ packet->expect_response =1 ; } -static void fill_iso_packet (struct hpsb_packet *packet,int length,int channel, -int tag,int sync) -{ - packet->header[0 ] = (length <<16 ) | (tag <<14 ) | (channel <<8 ) - | (TCODE_ISO_DATA <<4 ) | sync; - - packet->header_size =4 ; - packet->data_size = length; - packet->type = hpsb_iso; - packet->tcode =TCODE_ISO_DATA ; -} -static void fill_phy_packet (struct hpsb_packet *packet,quadlet_t data) { packet->header[0 ] = data;
@@ -470,24 +458,6 @@ struct hpsb_packet *hpsb_make_phypacket(return p; } -struct hpsb_packet *hpsb_make_isopacket (struct hpsb_host *host, -int length,int channel, -int tag,int sync) -{ -struct hpsb_packet *p; - - p =hpsb_alloc_packet (length); -if (!p) -return NULL ; - - p->host = host; -fill_iso_packet (p, length, channel, tag, sync); - - p->generation =get_hpsb_generation (host); - -return p; -} -/* * FIXME - these functions should probably read from / write to user space to * avoid in kernel buffers for user space callers
drivers/ieee1394/hosts.h renamed from drivers/ieee1394/hosts.h.old +0 -2
@@ -30,8 +30,6 @@ struct hpsb_host {struct timer_list timeout;unsigned long timeout_interval; -unsigned char iso_listen_count[64 ]; -int node_count;/* number of identified nodes on this bus */ int selfid_count;/* total number of SelfIDs received */ int nodes_active;/* number of nodes with active link layer */
drivers/ieee1394/raw1394-private.h renamed from drivers/ieee1394/raw1394-private.h.old +0 -5
@@ -36,11 +36,6 @@ struct file_info {u8 __user *fcp_buffer; -/* old ISO API */ -u64 listen_channels; -quadlet_t __user *iso_buffer; -size_t iso_buffer_length; -u8 notification;/* (busreset-notification) RAW1394_NOTIFY_OFF/ON */ /* new rawiso API */
Quoted 7 lines · Adrian Bunk
This patch contains the scheduled removal of requests of type
RAW1394_REQ_ISO_SEND,RAW1394_REQ_ISO_LISTEN.Signed-off-by Adrian Bunk <[email protected]>---
Quoted 11 lines
Documentation/feature-removal-schedule.txt | 9 - drivers/ieee1394/highlevel.c | 37 ---- drivers/ieee1394/highlevel.h | 21 -- drivers/ieee1394/hosts.h | 2 drivers/ieee1394/ieee1394_core.c | 7 drivers/ieee1394/ieee1394_transactions.c | 30 ---- drivers/ieee1394/ieee1394_transactions.h | 2 drivers/ieee1394/raw1394-private.h | 5 drivers/ieee1394/raw1394.c | 157 --------------------- drivers/ieee1394/raw1394.h | 4 10 files changed, 3 insertions(+), 271 deletions(-)
Thanks for this cleanup. Now that you did the work I hope you are not too upset that a recent discussion on linux1394-devel and libdc1394-devel concluded with another delay of the feature removal.
http://thread.gmane.org/gmane.linux.kernel.firewire.devel/8055
Here is what I sent to the lists after the discussion:
Date: Mon, 20 Nov 2006 00:05:05 +0100 (CET)
From: Stefan Richter <[email protected]>
Subject: ieee1394: raw1394: defer feature removal of old isoch interface
Known to be affected:
- libdc1394: prefers video1394 for now, old-style raw1394 support might be dropped eventually
- OpenH323 PWLib, AVC video input module: uses libraw1394's old API
--- Documentation/feature-removal-schedule.txt | 11 ++++++----- drivers/ieee1394/raw1394.c | 17 +++++++++++++++++ 2 files changed, 23 insertions(+), 5 deletions(-)
Documentation/feature-removal-schedule.txt +6 -5
@@ -30,11 +30,12 @@ Who: Adrian Bunk <[email protected]> --------------------------- What: raw1394: requests of type RAW1394_REQ_ISO_SEND, RAW1394_REQ_ISO_LISTEN -When: November 2006 -Why: Deprecated in favour of the new ioctl-based rawiso interface, which is - more efficient. You should really be using libraw1394 for raw1394 - access anyway. -Who: Jody McIntyre <[email protected]> +When: June 2007 +Why: Deprecated in favour of the more efficient and robust rawiso interface. + Affected are applications which use the deprecated part of libraw1394 + (raw1394_iso_write, raw1394_start_iso_write, raw1394_start_iso_rcv, + raw1394_stop_iso_rcv) or bypass libraw1394. +Who: Dan Dennedy <[email protected]>, Stefan Richter <[email protected]> ---------------------------
drivers/ieee1394/raw1394.c +17 -0
@@ -99,6 +99,21 @@ static struct hpsb_address_ops arm_ops =static void queue_complete_cb (struct pending_request *req); +#include <asm/current.h> +static void print_old_iso_deprecation (void ) +{ +static pid_t p; + +if (p == current->pid) +return ; + p = current->pid; +printk (KERN_WARNING "raw1394: WARNING - Program \"%s\" uses unsupported" +" isochronous request types which will be removed in a next" +" kernel release\n" , current->comm); +printk (KERN_WARNING "raw1394: Update your software to use libraw1394's" +" newer interface\n" ); +} +static struct pending_request *__alloc_pending_request (gfp_t flags) {struct pending_request *req;
@@ -2292,6 +2307,7 @@ static int state_connected(struct file_ireturn sizeof (struct raw1394_request );case RAW1394_REQ_ISO_SEND : +print_old_iso_deprecation ();return handle_iso_send (fi, req, node);case RAW1394_REQ_ARM_REGISTER :
@@ -2310,6 +2326,7 @@ static int state_connected(struct file_ireturn reset_notification (fi, req);case RAW1394_REQ_ISO_LISTEN : +print_old_iso_deprecation ();handle_iso_listen (fi, req);return sizeof (struct raw1394_request );
Signature · 3 lines
Stefan Richter -=====-=-==- =-== =-=-- http://arcgraph.de/sr/