Date: Mon, 27 Jul 2009 18:48:16 +0400 (MSD) From: Dmitry Morozovsky <marck@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/137177: sysutils/smartmontools: command13 fix Message-ID: <200907271448.n6REmGqZ026669@woozle.rinet.ru> Resent-Message-ID: <200907271510.n6RFA0kq008960@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 137177 >Category: ports >Synopsis: sysutils/smartmontools: command13 fix >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Mon Jul 27 15:10:00 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Dmitry Morozovsky >Release: FreeBSD 7-STABLE i386 >Organization: Cronyx Plus LLC (RiNet ISP) >Environment: System: FreeBSD 7-STABLE >Description: Cite from -stable@: This is stable/7 i386: $ smartctl -t select,568157535-568159000 /dev/ad10 ... Unrecognized command 13 in ata_command_interface() Please contact smartmontools-support@lists.sourceforge.net Error Write Selective Self-Test Log failed: Function not implemented In smartmontools sources this is command WRITE_LOG. >How-To-Repeat: >Fix: Submitted by: avg Index: Makefile =================================================================== RCS file: /home/ncvs/ports/sysutils/smartmontools/Makefile,v retrieving revision 1.40 diff -u -r1.40 Makefile --- Makefile 3 Jun 2009 18:12:29 -0000 1.40 +++ Makefile 27 Jul 2009 14:43:52 -0000 @@ -7,7 +7,7 @@ PORTNAME= smartmontools PORTVERSION= 5.38 -PORTREVISION= 6 +PORTREVISION= 7 CATEGORIES= sysutils MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= ${PORTNAME} Index: files/patch-os__freebsd.cpp =================================================================== RCS file: /home/ncvs/ports/sysutils/smartmontools/files/patch-os__freebsd.cpp,v retrieving revision 1.4 diff -u -r1.4 patch-os__freebsd.cpp --- files/patch-os__freebsd.cpp 21 May 2009 07:47:02 -0000 1.4 +++ files/patch-os__freebsd.cpp 27 Jul 2009 14:43:52 -0000 @@ -1,5 +1,8 @@ ---- os_freebsd.cpp.orig 2008-03-04 23:09:47.000000000 +0100 -+++ os_freebsd.cpp 2008-03-14 13:52:37.000000000 +0100 + +$FreeBSD$ + +--- os_freebsd.cpp.orig ++++ os_freebsd.cpp @@ -272,7 +272,6 @@ } @@ -8,16 +11,32 @@ return -1; } -@@ -525,7 +524,7 @@ +@@ -341,6 +340,15 @@ + request.count=512; + copydata=1; + break; ++ case WRITE_LOG: ++ memcpy(buff, data, 512); ++ request.u.ata.feature=ATA_SMART_WRITE_LOG_SECTOR; ++ request.u.ata.lba=select|(0xc24f<<8); ++ request.u.ata.count=1; ++ request.flags=ATA_CMD_WRITE; ++ request.data=(char *)buff; ++ request.count=512; ++ break; + case IDENTIFY: + request.u.ata.command=ATA_IDENTIFY_DEVICE; + request.flags=ATA_CMD_READ; +@@ -525,7 +533,7 @@ return -1; } - + - if ((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) { + if (((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) && ((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_SCSI_STATUS_ERROR)) { #if __FreeBSD_version > 500000 cam_error_print(cam_dev,ccb,CAM_ESF_ALL,CAM_EPF_ALL,stderr); #endif -@@ -924,6 +923,7 @@ +@@ -924,6 +932,7 @@ static const char * fbsd_dev_prefix = "/dev/"; static const char * fbsd_dev_ata_disk_prefix = "ad"; static const char * fbsd_dev_scsi_disk_plus = "da"; @@ -25,7 +44,7 @@ static const char * fbsd_dev_scsi_tape1 = "sa"; static const char * fbsd_dev_scsi_tape2 = "nsa"; static const char * fbsd_dev_scsi_tape3 = "esa"; -@@ -960,6 +960,11 @@ +@@ -960,6 +969,11 @@ return CONTROLLER_ATA; } >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200907271448.n6REmGqZ026669>