[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 01/18] qapi: Smarter camel_to_upper() to reduce need for 'pre
From: |
Markus Armbruster |
Subject: |
Re: [PATCH 01/18] qapi: Smarter camel_to_upper() to reduce need for 'prefix' |
Date: |
Wed, 31 Jul 2024 08:37:11 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Avihai Horon <avihaih@nvidia.com> writes:
> On 31/07/2024 8:12, Markus Armbruster wrote:
>> External email: Use caution opening links or attachments
>>
>>
>> Avihai Horon <avihaih@nvidia.com> writes:
>>
>>> On 30/07/2024 15:22, Markus Armbruster wrote:
>>>> Avihai, there's a question for you on VfioMigrationState.
>>>>
>>>> Daniel P. Berrangé <berrange@redhat.com> writes:
>>>>
>>>>> On Tue, Jul 30, 2024 at 10:10:15AM +0200, Markus Armbruster wrote:
>> [...]
>>
>>>> * VfioMigrationState
>>>>
>>>> Can't see why this one has a prefix. Avihai, can you enlighten me?
>>>
>>> linux-headers/linux/vfio.h defines enum vfio_device_mig_state with values
>>> VFIO_DEVICE_STATE_STOP etc.
>>
>> It does not define any VFIO_DEVICE_STATE_*, though.
>>
>>> I used the QAPI prefix to emphasize this is a QAPI entity rather than a
>>> VFIO entity.
>>
>> We define about two dozen symbols starting with VFIO_, and several
>> hundreds starting with vfio_. What makes this enumeration type
>> different so its members need emphasis?
>
> Right. I thought it would be clearer with the QAPI prefix because
> VFIO_DEVICE_STATE_* and VFIO_MIGRATION_STATE_* have similar values.
>
> But it's not a must. If you want to reduce prefix usage, go ahead, I don't
> have a strong opinion about it.
Thanks!
- Re: [PATCH 07/18] qapi/machine: Drop temporary 'prefix', (continued)
Re: [PATCH 01/18] qapi: Smarter camel_to_upper() to reduce need for 'prefix', Kevin Wolf, 2024/07/31
[PATCH 04/18] qapi/common: Drop temporary 'prefix', Markus Armbruster, 2024/07/30
[PATCH 10/18] qapi/crypto: Drop unwanted 'prefix', Markus Armbruster, 2024/07/30
[PATCH 09/18] qapi/machine: Rename CpuS390* to S390Cpu, and drop 'prefix', Markus Armbruster, 2024/07/30
[PATCH 15/18] qapi/crypto: Rename QCryptoRSAPaddingAlgorithm to *Algo, and drop prefix, Markus Armbruster, 2024/07/30