IP Library › Granted Patent US 9,417,801
Granted Patent B2
US 9,417,801 · App. 14/227,735 · Granted Aug 16, 2016

Virtual general-purpose I/O controller

Inventors: Nicholas J. Adams (Beaverton, OR); Robert E. Gough (Sherwood, OR); Sai Prasad Paithara Balagangadhara (Folsom, CA); Pronay Dutta (Beaverton, OR)
Assignee: Intel Corporation
G06F3/0611G06F3/0659G06F3/0673G06F13/24G06F13/385
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,417,801
App. No.
14/227,735
Granted
Aug 16, 2016
Kind
B2
Abstract

Technologies for virtual general purpose I/O (GPIO) include a computing device having a virtual GPIO controller driver, a virtual GPIO controller firmware interface, and a virtual GPIO controller. The driver receives a GPIO command from an operating system of the computing device. The GPIO command specifies an operation to be performed by a GPIO pin. The driver sends the GPIO command to the firmware interface. In response to the firmware interface receiving the command, the virtual GPIO controller emulates a virtual GPIO pin to implement the GPIO command. The firmware interface may trigger an interrupt that can be received by the operating system. The virtual GPIO controller may emulate the virtual GPIO pin using firmware-reserved backing memory, an embedded controller, or an interface to a peripheral device of the computing device. The firmware interface may be an ACPI control method. Other embodiments are described and claimed.

Claims (64)

1. A computing device for emulating general purpose I/O (GPIO), the computing device comprising a virtual GPIO controller driver, a virtual GPIO controller firmware interface, and a virtual GPIO controller, wherein:

the virtual GPIO controller firmware interface comprises a programmatic interface established by platform firmware of the computing device;

the virtual GPIO controller driver is to (i) receive a GPIO command from an operating system of the computing device, the GPIO command to specify an operation to be implemented by a GPIO pin, and (ii) invoke the virtual GPIO controller firmware interface with the GPIO command in response to receipt of the GPIO command;

the virtual GPIO firmware interface is to receive the GPIO command from the virtual GPIO controller driver in response to invocation of the virtual GPIO firmware interface; and

the virtual GPIO controller is to emulate a virtual GPIO pin to implement the GPIO command in response to receipt of the GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver.

2. The computing device of claim 1 , wherein:

the virtual GPIO controller driver is further to (i) receive a second GPIO command the second GPIO command to specify an operation to be implemented by a second GPIO pin, and (ii) invoke the virtual GPIO controller firmware interface with the second GPIO command in response to receipt of the second GPIO command;

the virtual GPIO controller firmware interface is further to receive the second GPIO command from the virtual GPIO controller driver in response to invocation of the virtual GPIO firmware interface; and

the virtual GPIO controller is further to emulate a second virtual GPIO pin to implement the second GPIO command in response to receipt of the second GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver.

3. The computing device of claim 1 , wherein to emulate the virtual GPIO pin comprises to emulate the virtual GPIO pin using a microcontroller of the computing device as the virtual GPIO pin.

4. The computing device of claim 3 , wherein to emulate the virtual GPIO pin further comprises to emulate the virtual GPIO pin using a physical GPIO pin of the microcontroller as the virtual GPIO pin.

5. The computing device of claim 3 , wherein the virtual GPIO controller is further to emulate a second virtual GPIO pin using the microcontroller of the computing device as the second virtual GPIO pin.

6. The computing device of claim 1 , wherein to emulate the virtual GPIO pin comprises to emulate the virtual GPIO pin using an interface to a peripheral device of the computing device as the virtual GPIO pin.

7. The computing device of claim 1 , wherein the virtual GPIO controller is further to:

receive a GPIO event, the GPIO event related to a state of the virtual GPIO pin; and

emulate the virtual GPIO pin to modify the state of the virtual GPIO pin as a function of the GPIO event.

8. The computing device of claim 7 , wherein:

the GPIO event comprises an I/O event received from a microcontroller of the computing device; and

to emulate the virtual GPIO pin comprises to modify the state of the virtual GPIO pin as a function of the I/O event.

9. The computing device of claim 8 , wherein the virtual GPIO controller is further to emulate a second virtual GPIO pin using the microcontroller of the computing device as the second virtual GPIO pin.

10. The computing device of claim 7 , wherein the virtual GPIO controller firmware interface is further to trigger a physical interrupt by an I/O subsystem of the computing device to the operating system in response to a modification of the state of the virtual GPIO pin.

11. The computing device of claim 1 , wherein:

the virtual GPIO controller firmware interface comprises: a control method for a virtual machine, the control method to be interpreted by a bytecode interpreter of the computing device, and (ii) an advanced configuration and power interface (ACPI) device that includes a plurality of ACPI control methods; and

to invoke the virtual GPIO controller firmware interface comprises to invoke the control method.

12. A method for emulating general purpose I/O (GPIO) on a computing device, the method comprising:

receiving a GPIO command by a virtual GPIO controller driver of an operating system of the computing device, the GPIO command to specify an operation to be implemented by a GPIO pin;

invoking, by the virtual GPIO controller driver, a virtual GPIO controller firmware interface with the GPIO command in response to receiving the GPIO command wherein the virtual GPIO controller firmware interface comprises a programmatic interface established by platform firmware of the computing device;

receiving the GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver in response to invoking the virtual GPIO controller firmware interface; and

emulating, by a virtual GPIO controller of the computing device, a virtual GPIO pin to implement the GPIO command in response to receiving the GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver.

13. The method of claim 12 , further comprising:

receiving a second GPIO command by the virtual GPIO controller driver, the second GPIO command to specify an operation to be implemented by a second GPIO pin;

invoking, by the virtual GPIO controller driver, the virtual GPIO controller firmware interface with the second GPIO command in response to receiving the second GPIO command;

receiving the second GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver in response to invoking the virtual GPIO controller firmware interface; and

emulating, by the virtual GPIO controller of the computing device, a second virtual GPIO pin to implement the second GPIO command in response to receiving the second GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver.

14. The method of claim 12 , wherein emulating the virtual GPIO pin comprises emulating the virtual GPIO pin using a microcontroller of the computing device as the virtual GPIO pin.

15. The method of claim 12 , wherein emulating the virtual GPIO pin comprises emulating the virtual GPIO pin using an interface to a peripheral device of the computing device as the virtual GPIO pin.

16. The method of claim 12 , further comprising:

receiving a GPIO event by the virtual GPIO controller, the GPIO event related to a state of the virtual GPIO pin; and

emulating, by the virtual GPIO controller, the virtual GPIO pin to modify the state of the virtual GPIO pin as a function of the GPIO event.

17. The method of claim 16 , further comprising triggering, by the virtual GPIO controller firmware interface, a physical interrupt by an I/O subsystem of the computing device to the operating system in response to modifying the state of the virtual GPIO pin.

18. The method of claim 12 , wherein the virtual GPIO controller firmware interface comprises:

a control method for a virtual machine, the control method to be interpreted by a bytecode interpreter of the computing device; and

an advanced configuration and power interface (ACPI) device including a plurality of ACPI control methods; and

wherein invoking the virtual GPIO controller firmware interface comprises invoking the control method.

19. One or more non-transitory, computer-readable storage media comprising a plurality of instructions that in response to being executed cause a computing device to:

receive a general-purpose I/O (GPIO) command by a virtual GPIO controller driver of an operating system of the computing device, the GPIO command to specify an operation to be implemented by a GPIO pin;

invoke, by the virtual GPIO controller driver, a virtual GPIO controller firmware interface with the GPIO command in response to receiving the GPIO command, wherein the virtual GPIO controller firmware interface comprises a programmatic interface established by platform firmware of the computing device;

receive the GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver in response to invoking the virtual GPIO controller firmware interface; and

emulate, by a virtual GPIO controller of the computing device, a virtual GPIO pin to implement the GPIO command in response to receiving the GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver.

20. The one or more non-transitory, computer-readable storage media of claim 19 , further comprising a plurality of instructions that in response to being executed cause the computing device to:

receive a second GPIO command by the virtual GPIO controller driver, the second GPIO command to specify an operation to be implemented by a second GPIO pin;

invoke, by the virtual GPIO controller driver, the virtual GPIO controller firmware interface with the second GPIO command in response to receiving the second GPIO command;

receive the second GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver in response to invoking the virtual GPIO controller firmware interface; and

emulate, by the virtual GPIO controller of the computing device, a second virtual GPIO pin to implement the second GPIO command in response to receiving the second GPIO command by the virtual GPIO controller firmware interface from the virtual GPIO controller driver.

21. The one or more non-transitory, computer-readable storage media of claim 19 , wherein to emulate the virtual GPIO pin comprises to emulate the virtual GPIO pin using a microcontroller of the computing device as the virtual GPIO pin.

22. The one or more non-transitory, computer-readable storage media of claim 19 , wherein to emulate the virtual GPIO pin comprises to emulate the virtual GPIO pin using an interface to a peripheral device of the computing device as the virtual GPIO pin.

23. The one or more non-transitory, computer-readable storage media of claim 19 , further comprising a plurality of instructions that in response to being executed cause the computing device to:

receive a GPIO event by the virtual GPIO controller, the GPIO event related to a state of the virtual GPIO pin; and

emulate, by the virtual GPIO controller, the virtual GPIO pin to modify the state of the virtual GPIO pin as a function of the GPIO event.

24. The one or more non-transitory, computer-readable storage media of claim 23 , further comprising a plurality of instructions that in response to being executed cause the computing device to trigger, by the virtual GPIO controller firmware interface, a physical interrupt by an I/O subsystem of the computing device to the operating system in response to a modification of the state of the virtual GPIO pin.

25. The one or more non-transitory, computer-readable storage media of claim 19 , wherein the virtual GPIO controller firmware interface comprises:

a control method for a virtual machine, the control method to be interpreted by a bytecode interpreter of the computing device; and

an advanced configuration and power interface (ACPI) device including a plurality of ACPI control methods; and

wherein to invoke the virtual GPIO controller firmware interface comprises to invoke the control method.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 5, 2014
From: ADAMS, NICHOLAS J; GOUGH, ROBERT E; BALAGANGADHARA, SAI PRASAD PAITHARA; DUTTA, PRONAY
To: INTEL CORPORATION
Reel/Frame 033682/0328 →
Continuity (1)
Related Publication 20150277778A1 · Oct 1, 2015