Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Enumerations | Functions | Variables
drp.c File Reference
#include <linux/kthread.h>
#include <linux/freezer.h>
#include <linux/slab.h>
#include <linux/delay.h>
#include "uwb-internal.h"

Go to the source code of this file.

Enumerations

enum  uwb_drp_conflict_action { UWB_DRP_CONFLICT_MANTAIN = 0, UWB_DRP_CONFLICT_ACT1, UWB_DRP_CONFLICT_ACT2, UWB_DRP_CONFLICT_ACT3 }
 

Functions

int uwb_rc_send_all_drp_ie (struct uwb_rc *rc)
 
int uwbd_evt_handle_rc_drp (struct uwb_event *evt)
 

Variables

enum uwb_drp_conflict_action __attribute__
 

Enumeration Type Documentation

Enumerator:
UWB_DRP_CONFLICT_MANTAIN 
UWB_DRP_CONFLICT_ACT1 
UWB_DRP_CONFLICT_ACT2 
UWB_DRP_CONFLICT_ACT3 

Definition at line 29 of file drp.c.

Function Documentation

int uwb_rc_send_all_drp_ie ( struct uwb_rc rc)

Construct and send the SET DRP IE

: UWB Host controller

Returns
: >= 0 number of bytes still available in the beacon < 0 errno code on error.

See WUSB[8.6.2.7]: The host must set all the DRP IEs that it wants the device to include in its beacon at the same time. We thus have to traverse all reservations and include the DRP IEs of all PENDING and NEGOTIATED reservations in a SET DRP command for transmission.

A DRP Availability IE is appended.

rc->rsvs_mutex is held

FIXME We currently ignore the returned value indicating the remaining space in beacon. This could be used to deny reservation requests earlier if determined that they would cause the beacon space to be exceeded.

Definition at line 100 of file drp.c.

int uwbd_evt_handle_rc_drp ( struct uwb_event evt)

uwbd_evt_handle_rc_drp - handle a DRP_IE event : the DRP_IE event from the radio controller

This processes DRP notifications from the radio controller, either initiating a new reservation or transitioning an existing reservation into a different state.

DRP notifications can occur for three different reasons:

  • UWB_DRP_NOTIF_DRP_IE_RECVD: one or more DRP IEs with the RC as the target or source have been received.

    These DRP IEs could be new or for an existing reservation.

    If the DRP IE for an existing reservation ceases to be to received for at least mMaxLostBeacons, the reservation should be considered to be terminated. Note that the TERMINATE reason (see below) may not always be signalled (e.g., the remote device has two or more reservations established with the RC).

  • UWB_DRP_NOTIF_CONFLICT: DRP IEs from any device in the beacon group conflict with the RC's reservations.
  • UWB_DRP_NOTIF_TERMINATE: DRP IEs are no longer being received from a device (i.e., it's terminated all reservations).

Only the software state of the reservations is changed; the setting of the radio controller's DRP IEs is done after all the events in an event buffer are processed. This saves waiting multiple times for the SET_DRP_IE command to complete.

Definition at line 765 of file drp.c.

Variable Documentation