This is the closest way to disabling it without using the "libata.force=noncq" kernel boot option is to set the queue to a depth of 1 which doesn't actually disable it.
Change the sdc below to match the device you want to disable NCQ for.
[root@officebox ~]# echo "1" > /sys/block/sdc/device/queue_depth
Errors that indicate you are having a performance issue are these in messages or dmesg relating to NCQ and SATA bus timeout and reset are killing your IO performance!
Apr 12 12:12:50 officebox kernel: ata8: EH in SWNCQ mode,QC:qc_active 0x400FFFFF sactive 0x400FFFFF
Apr 12 12:12:50 officebox kernel: ata8: SWNCQ:qc_active 0x40000007 defer_bits 0xFFFF8 last_issue_tag 0x2
Apr 12 12:12:50 officebox kernel: dhfis 0x40000003 dmafis 0x40000008 sdbfis 0x0
Apr 12 12:12:50 officebox kernel: ata8: ATA_REG 0x51 ERR_REG 0x84
Apr 12 12:12:50 officebox kernel: ata8: tag : dhfis dmafis sdbfis sacitve
Apr 12 12:12:50 officebox kernel: ata8: tag 0x0: 1 0 0 1
Apr 12 12:12:50 officebox kernel: ata8: tag 0x1: 1 0 0 1
Apr 12 12:12:50 officebox kernel: ata8: tag 0x2: 0 0 0 1
Apr 12 12:12:50 officebox kernel: ata8: tag 0x1e: 1 1 0 1
Apr 12 12:12:50 officebox kernel: ata8.00: exception Emask 0x1 SAct 0x400fffff SErr 0x0 action 0x6 frozen
Apr 12 12:12:50 officebox kernel: ata8.00: Ata error. fis:0x21
Apr 12 12:12:50 officebox kernel: ata8.00: failed command: WRITE FPDMA QUEUED
Apr 12 12:12:50 officebox kernel: ata8.00: cmd 61/08:00:bf:83:8b/00:00:02:00:00/40 tag 0 ncq 4096 out
Apr 12 12:12:50 officebox kernel: res 51/84:10:d7:83:8b/84:00:02:00:00/40 Emask 0x10 (ATA bus error)
Apr 12 12:12:50 officebox kernel: ata8.00: status: { DRDY ERR }
Apr 12 12:12:50 officebox kernel: ata8.00: error: { ICRC ABRT }
Apr 12 12:12:50 officebox kernel: ata8.00: failed command: WRITE FPDMA QUEUED
Apr 12 12:12:50 officebox kernel: ata8.00: cmd 61/10:08:c7:83:8b/00:00:02:00:00/40 tag 1 ncq 8192 out
Apr 12 12:12:50 officebox kernel: res 51/84:10:d7:83:8b/84:00:02:00:00/40 Emask 0x10 (ATA bus error)
Apr 12 12:12:50 officebox kernel: ata8.00: status: { DRDY ERR }
Apr 12 12:12:50 officebox kernel: ata8.00: error: { ICRC ABRT }
Apr 12 12:12:50 officebox kernel: ata8.00: failed command: WRITE FPDMA QUEUED
Apr 12 12:12:50 officebox kernel: ata8.00: cmd 61/18:10:d7:83:8b/00:00:02:00:00/40 tag 2 ncq 12288 out
Apr 12 12:12:50 officebox kernel: res 51/84:10:d7:83:8b/84:00:02:00:00/40 Emask 0x10 (ATA bus error)
Apr 12 12:12:50 officebox kernel: ata8.00: status: { DRDY ERR }
Apr 12 12:12:50 officebox kernel: ata8.00: error: { ICRC ABRT }
Apr 12 12:12:50 officebox kernel: ata8.00: failed command: WRITE FPDMA QUEUED
Apr 12 12:12:50 officebox kernel: ata8.00: cmd 61/10:18:ef:83:8b/00:00:02:00:00/40 tag 3 ncq 8192 out
Apr 12 12:12:50 officebox kernel: res 51/84:10:d7:83:8b/84:00:02:00:00/40 Emask 0x10 (ATA bus error)
:
linux, disable, sata, ncq, performancethis, disabling, quot, libata, noncq, kernel, queue, depth, doesn, sdc, officebox, echo, sys, queue_depth, errors, indicate, dmesg, relating, timeout, reset, io, apr, ata, swncq, mode, qc, qc_active, fffff, sactive, defer_bits, xffff, last_issue_tag, dhfis, dmafis, sdbfis, ata_reg, err_reg, sacitve, exception, emask, sact, serr, fis, fpdma, queued, cmd, bf, res, drdy, err, icrc, abrt, ef,