qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 13/15] qapi: add HOTPLUG_STATE event


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH v3 13/15] qapi: add HOTPLUG_STATE event
Date: Fri, 10 Feb 2023 12:20:24 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.7.2

On 10/2/23 11:47, Vladimir Sementsov-Ogievskiy wrote:
On 10.02.23 00:28, Philippe Mathieu-Daudé wrote:
On 9/2/23 21:08, Vladimir Sementsov-Ogievskiy wrote:
For PCIe and SHPC hotplug it's important to track led indicators,
especially the power led. Add an event that helps.

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
---
  qapi/qdev.json       | 62 ++++++++++++++++++++++++++++++++++++++++++++
  include/hw/pci/pci.h | 15 +++++++++++
  hw/pci/pci.c         | 33 +++++++++++++++++++++++
  hw/pci/pcie.c        | 49 ++++++++++++++++++++++++++++++++++
  hw/pci/shpc.c        | 42 ++++++++++++++++++++++++++++++
  5 files changed, 201 insertions(+)

diff --git a/qapi/qdev.json b/qapi/qdev.json
index 2708fb4e99..40dc34f091 100644
--- a/qapi/qdev.json
+++ b/qapi/qdev.json
@@ -158,3 +158,65 @@
  ##
  { 'event': 'DEVICE_UNPLUG_GUEST_ERROR',
    'data': { '*device': 'str', 'path': 'str' } }
+
+##
+# @HotplugLedState:
+#
+# Since: 8.0
+##
+{ 'enum': 'HotplugLedState',
+  'data': [ 'on', 'blink', 'off' ] }

Could this be more helpful as generic state in "hw/misc/led.h"?

Hmm. LEDState ? Doesn't look similar..

Name 'LedActivity' so we can reuse in LEDState?

  { 'enum': 'LedActivity',
    'data': [ 'on', 'blink', 'off' ] }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]