Skip to main content

Proposed MPEOS API addition to set DLNA QOS on socket

  4 posts   Feedicon  
Replies: 3 - Last Post: July 17, 2012 22:26
by: Chris Sweeney
showing 1 - 4 of 4
Posted: June 19, 2012 20:49 by mmas
To support setting the default DLNA QOS value on a socket the following api addition is proposed.

Index: mpeos_socket.h
===================================================================
--- mpeos_socket.h (revision 35298)
+++ mpeos_socket.h (working copy)
@@ -2030,6 +2030,15 @@
*/
void mpeos_socketFreeInterfaces(mpe_SocketNetIfList *netIfList);

+/**
+ * Set the QOS(Quality of Service) value for a socket
+ *
+ * @param sock is the socket to set QOS on
+ * @param value is the value to set
+ *
+ */
+void mpeos_socketSetQOS(mpe_Socket sock, int value);
+

please provide comments
Posted: June 25, 2012 23:01 by mmas

Based on comments I received from RI team here are proposed changes to the original post

$ svn diff ./os/include/mpeos_socket.h
Index: os/include/mpeos_socket.h
===================================================================
--- os/include/mpeos_socket.h (revision 35539)
+++ os/include/mpeos_socket.h (working copy)
@@ -380,6 +380,19 @@

#endif

+/**
+ * This data type enumerates the allowable DLNA QOS DSCP values set by the
+ * mpe_socketSetQOS API. Refer to DLNA Guidelines Part 1 for DLNA QOS
+ * recommendations.
+ */
+typedef enum
+{
+ MPE_SOCKET_DLNA_QOS_0 = 0x08,
+ MPE_SOCKET_DLNA_QOS_1 = 0x00,
+ MPE_SOCKET_DLNA_QOS_2 = 0x28,
+ MPE_SOCKET_DLNA_QOS_3 = 0x38
+} mpe_SocketDLNAQOS;
+
/****************************************************************************************
*
* SOCKET LEVEL OPTIONS
@@ -2030,6 +2043,24 @@
*/
void mpeos_socketFreeInterfaces(mpe_SocketNetIfList *netIfList);

+/**
+ * Sets the DLNA QOS(Quality of Service) value for a socket
+ * This is the DSCP value set in the TOS field of the IP header.
+ * This API restricts the allowable values to the values
+ * defined by mpe_SocketDLNAQOS. A value other than those defined
+ * by mpe_SocketDLNAQOS results in a MPE_EINVAL return code.
+ *
+ * @param sock is the socket to set QOS on
+ * @param value is the value to set
+ *
+ * @return Upon successful completion, returns MPE_SUCCESS
+ * <ul>
+ * <li> MPE_EINVAL - value other than those defined by mpe_SocketDLNAQOS.
+ * <li> MPE_ENODATA - any other error.
+ * </ul>
+ */
+mpe_Error mpeos_socketSetDLNAQOS(mpe_Socket sock, mpe_SocketDLNAQOS value);
+
#ifdef __cplusplus
}
#endif

Posted: July 17, 2012 13:17 by mmas

These changes were committed to trunk svn revision 35756
Posted: July 17, 2012 22:26 by Chris Sweeney
Removing from scraper.
Replies: 3 - Last Post: July 17, 2012 22:26
by: Chris Sweeney
 
 
Close
loading
Please Confirm
Close