[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 06/16] ahci: add ncq debug checks
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH 06/16] ahci: add ncq debug checks |
Date: |
Mon, 22 Jun 2015 15:14:44 +0100 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Fri, Jun 19, 2015 at 09:50:37PM -0400, John Snow wrote:
> @@ -1003,6 +1003,27 @@ static void process_ncq_command(AHCIState *s, int
> port, uint8_t *cmd_fis,
> (uint64_t)ncq_fis->lba0;
> ncq_tfs->tag = tag;
>
> +#ifdef DEBUG_AHCI
These sorts of debug ifdefs have a tendency to bitrot since the code
isn't compiled.
There is no need for the ifdef since DPRINTF() is deadcode when DEBUG_AHCI
is 0. The compiler parses the code, preventing bitrot, but optimizes
the code away when DEBUG_ACHI is 0.
pgpOUgHn8Mezr.pgp
Description: PGP signature
[Qemu-devel] [PATCH 02/16] ahci: use shorter variables, John Snow, 2015/06/19
[Qemu-devel] [PATCH 05/16] ahci: separate prdtl from opts, John Snow, 2015/06/19
[Qemu-devel] [PATCH 08/16] ahci: clear error register before NCQ cmd, John Snow, 2015/06/19