Index: uspace/lib/usbvirt/device.h
===================================================================
--- uspace/lib/usbvirt/device.h	(revision bbfb86c7c8c98f4ce1b66eb942b45b98967bb177)
+++ uspace/lib/usbvirt/device.h	(revision 08af5a623a5800b0ab77eab5b167487adcdfe5ca)
@@ -104,4 +104,6 @@
 	/** Number of configurations. */
 	size_t configuration_count;
+	/** Index of currently selected configuration. */
+	uint8_t current_configuration;
 } usbvirt_descriptors_t;
 
Index: uspace/lib/usbvirt/stdreq.c
===================================================================
--- uspace/lib/usbvirt/stdreq.c	(revision bbfb86c7c8c98f4ce1b66eb942b45b98967bb177)
+++ uspace/lib/usbvirt/stdreq.c	(revision 08af5a623a5800b0ab77eab5b167487adcdfe5ca)
@@ -132,4 +132,43 @@
 }
 
+static int handle_set_configuration(uint16_t configuration_value,
+    uint16_t zero1, uint16_t zero2)
+{
+	if ((zero1 != 0) || (zero2 != 0)) {
+		return EINVAL;
+	}
+	
+	/*
+	 * Configuration value is 1 byte information.
+	 */
+	if (configuration_value > 255) {
+		return EINVAL;
+	}
+	
+	/*
+	 * Do nothing when in default state. According to specification,
+	 * this is not specified.
+	 */
+	if (device->state == USBVIRT_STATE_DEFAULT) {
+		return EOK;
+	}
+	
+	if (configuration_value == 0) {
+		device->state = USBVIRT_STATE_ADDRESS;
+	} else {
+		/*
+		* TODO: browse provided configurations and verify that
+		* user selected existing configuration.
+		*/
+		device->state = USBVIRT_STATE_CONFIGURED;
+		if (device->descriptors) {
+			device->descriptors->current_configuration
+			    = configuration_value;
+		}
+	}
+		
+	return EOK;
+}
+
 #define HANDLE_REQUEST(request, data, type, dev, user_callback, default_handler) \
 	do { \
@@ -161,4 +200,9 @@
 	        request->index, request->length));
 	
+	HANDLE_REQUEST(request, data, USB_DEVREQ_SET_CONFIGURATION,
+	    device, on_set_configuration,
+	    handle_set_configuration(request->value,
+	        request->index, request->length));
+	
 	return ENOTSUP;
 }
