Hello community,
here is the log from the commit of package hdparm for openSUSE:Factory
checked in at Mon Mar 2 17:51:14 CET 2009.
--------
--- hdparm/hdparm.changes 2009-02-16 10:50:51.000000000 +0100
+++ /mounts/work_src_done/STABLE/hdparm/hdparm.changes 2009-03-02 09:40:42.000000000 +0100
@@ -1,0 +2,10 @@
+Mon Mar 2 09:32:59 CET 2009 - mseben@suse.cz
+
+- update to version 9.12
+ * added logical/physical sector size reporting
+ * updated -I output with SATA-2.6 additions
+ * support APM level retrieval with -B flag
+ * updated -C output to match ATA8
+ * added "form factor" and "rotation" display to -I, courtesy of Martin K.Petersen.
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
hdparm-9.11-nostrip.patch
hdparm-9.11.tar.bz2
New:
----
hdparm-9.12-nostrip.patch
hdparm-9.12.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ hdparm.spec ++++++
--- /var/tmp/diff_new_pack.K12529/_old 2009-03-02 17:51:05.000000000 +0100
+++ /var/tmp/diff_new_pack.K12529/_new 2009-03-02 17:51:05.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package hdparm (Version 9.11)
+# spec file for package hdparm (Version 9.12)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -24,7 +24,7 @@
PreReq: %insserv_prereq %fillup_prereq coreutils
Provides: base:/sbin/hdparm
AutoReqProv: on
-Version: 9.11
+Version: 9.12
Release: 1
Summary: A Program to Get and Set Hard Disk Parameters
Source: %{name}-%{version}.tar.bz2
@@ -116,6 +116,13 @@
/var/adm/fillup-templates/sysconfig.ide
%changelog
+* Mon Mar 02 2009 mseben@suse.cz
+- update to version 9.12
+ * added logical/physical sector size reporting
+ * updated -I output with SATA-2.6 additions
+ * support APM level retrieval with -B flag
+ * updated -C output to match ATA8
+ * added "form factor" and "rotation" display to -I, courtesy of Martin K.Petersen.
* Mon Feb 16 2009 mseben@suse.cz
- update to version 9.11
* switch back to ATA_16 by default: required by libata for ATAPI devices
++++++ hdparm-9.11-nostrip.patch -> hdparm-9.12-nostrip.patch ++++++
++++++ hdparm-9.11.tar.bz2 -> hdparm-9.12.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hdparm-9.11/Changelog new/hdparm-9.12/Changelog
--- old/hdparm-9.11/Changelog 2009-01-29 20:38:12.000000000 +0100
+++ new/hdparm-9.12/Changelog 2009-02-26 19:10:14.000000000 +0100
@@ -1,3 +1,9 @@
+hdparm-9.12
+ - added logical/physical sector size reporting
+ - updated -I output with SATA-2.6 additions
+ - support APM level retrieval with -B flag
+ - updated -C output to match ATA8
+ - added "form factor" and "rotation" display to -I, courtesy of Martin K.Petersen.
hdparm-9.11
- switch back to ATA_16 by default: required by libata for ATAPI devices
- add --prefer-ata12 to force use of ATA_12 when needed (some USB enclosures)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hdparm-9.11/dvdspeed.c new/hdparm-9.12/dvdspeed.c
--- old/hdparm-9.11/dvdspeed.c 2008-12-10 00:49:09.000000000 +0100
+++ new/hdparm-9.12/dvdspeed.c 2009-01-31 04:17:08.000000000 +0100
@@ -5,6 +5,7 @@
#include
#include
#include
+#include "hdparm.h"
/*
* dvdspeed - use SET STREAMING command to set the speed of DVD-drives
*
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hdparm-9.11/hdparm.8 new/hdparm-9.12/hdparm.8
--- old/hdparm-9.11/hdparm.8 2009-01-29 20:36:15.000000000 +0100
+++ new/hdparm-9.12/hdparm.8 2009-02-12 14:56:36.000000000 +0100
@@ -1,4 +1,4 @@
-.TH HDPARM 8 "January 2009" "Version 9.11"
+.TH HDPARM 8 "February 2009" "Version 9.12"
.SH NAME
hdparm \- get/set SATA/IDE device parameters
@@ -41,7 +41,7 @@
Get/set bus state.
.TP
.I -B
-Set Advanced Power Management feature, if the drive supports it. A low value
+Query/set Advanced Power Management feature, if the drive supports it. A low value
means aggressive power management and a high value means better performance.
Possible settings range from values 1 through 127 (which permit spin-down),
and values 128 through 254 (which do not permit spin-down).
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hdparm-9.11/hdparm.c new/hdparm-9.12/hdparm.c
--- old/hdparm-9.11/hdparm.c 2009-01-29 20:32:52.000000000 +0100
+++ new/hdparm-9.12/hdparm.c 2009-02-26 19:10:22.000000000 +0100
@@ -25,7 +25,7 @@
extern const char *minor_str[];
-#define VERSION "v9.11"
+#define VERSION "v9.12"
#ifndef O_DIRECT
#define O_DIRECT 040000 /* direct disk access, not easily obtained from headers */
@@ -1671,14 +1671,19 @@
}
if (get_powermode) {
__u8 args[4] = {ATA_OP_CHECKPOWERMODE1,0,0,0};
- const char *state;
+ const char *state = "unknown";
if (do_drive_cmd(fd, args)
&& (args[0] = ATA_OP_CHECKPOWERMODE2) /* (single =) try again with 0x98 */
&& do_drive_cmd(fd, args)) {
err = errno;
- state = "unknown";
} else {
- state = (args[2] == 255) ? "active/idle" : "standby";
+ switch (args[2]) {
+ case 0x00: state = "standby"; break;
+ case 0x40: state = "NVcache_spindown"; break;
+ case 0x41: state = "NVcache_spinup"; break;
+ case 0x80: state = "idle"; break;
+ case 0xff: state = "active/idle"; break;
+ }
}
printf(" drive state is: %s\n", state);
}
@@ -1734,6 +1739,17 @@
}
}
}
+ if (get_apmmode) {
+ id = get_identify_data(fd, id);
+ printf(" APM_level = ");
+ if((id[83] & 0xc008) == 0x4008) {
+ if (id[86] & 0x0008)
+ printf("%u\n", id[91] & 0xff);
+ else
+ printf("off\n");
+ } else
+ printf("not supported\n");
+ }
if (get_acoustic) {
id = get_identify_data(fd, id);
if (id) {
@@ -2307,7 +2323,7 @@
case GET_SET_PARM('a',"filesystem-read-ahead",fsreadahead,0,2048);
case GET_SET_PARM('A',"look-ahead",lookahead,0,1);
case GET_SET_PARM('b',"bus-state",busstate,0,2);
- case SET_PARM('B',"power-management-mode",apmmode,1,255);
+ case GET_SET_PARM('B',"power-management-mode",apmmode,0,255);
case GET_SET_PARM('c',"32-bit-IO",io32bit,0,3);
case SET_FLAG('C',powermode);
case GET_SET_PARM('d',"dma-enable",dma,0,1);
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hdparm-9.11/hdparm.lsm new/hdparm-9.12/hdparm.lsm
--- old/hdparm-9.11/hdparm.lsm 2009-01-29 20:37:47.000000000 +0100
+++ new/hdparm-9.12/hdparm.lsm 2009-02-26 19:13:10.000000000 +0100
@@ -1,8 +1,9 @@
Begin4
Title: hdparm
-Version: 9.11
-Entered-date: 2009-01-29
+Version: 9.12
+Entered-date: 2009-02-26
Description: hdparm - get/set hard disk parameters for Linux SATA/IDE drives.
+ v9.12 Lots of -I updates, -C updates; -B now reports current APM setting
v9.11 Fixed -I for ATAPI; added --prefer-ata12 for some USB enclosures
v9.10 Fixes for CF card detection/reporting
v9.9 Recalculate cyls when kernel returns a truncated value
@@ -85,7 +86,7 @@
Maintained-by: mlord@pobox.com (Mark Lord)
Primary-site: http://sourceforge.net/projects/hdparm/
Alternate-site: http://www.ibiblio.org/pub/Linux/system/hardware
- 96K hdparm-9.11.tar.gz
+ 96K hdparm-9.12.tar.gz
4K hdparm.lsm
Platforms: Linux, kernels 2.2 through 2.6
Copying-policy: BSD License
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hdparm-9.11/identify.c new/hdparm-9.12/identify.c
--- old/hdparm-9.11/identify.c 2009-01-27 18:48:41.000000000 +0100
+++ new/hdparm-9.12/identify.c 2009-02-26 19:09:58.000000000 +0100
@@ -103,6 +103,7 @@
#define SCT_SUPP 206 /* SMART command transport (SCT) support */
#define TRANSPORT_MAJOR 222 /* PATA vs. SATA etc.. */
#define TRANSPORT_MINOR 223 /* minor revision number */
+#define NMRR 217 /* nominal media rotation rate */
#define INTEGRITY 255 /* integrity word */
/* bit definitions within the words */
@@ -406,8 +407,8 @@
"unknown 76[15]", /* word 76 bit 15 */
"unknown 76[14]", /* word 76 bit 14 */
"unknown 76[13]", /* word 76 bit 13 */
- "unknown 76[12]", /* word 76 bit 12 */
- "unknown 76[11]", /* word 76 bit 11 */
+ "NCQ priority information", /* word 76 bit 12 */
+ "Idle-Unload when NCQ is active", /* word 76 bit 11 */
"Phy event counters", /* word 76 bit 10 */
"Host-initiated interface power management", /* word 76 bit 9 */
"Native Command Queueing (NCQ)", /* word 76 bit 8 */
@@ -416,8 +417,8 @@
"unknown 76[5]", /* word 76 bit 5 */
"unknown 76[4]", /* word 76 bit 4 */
"unknown 76[3]", /* word 76 bit 3 */
- "SATA-II signaling speed (3.0Gb/s)", /* word 76 bit 2 */
- "SATA-I signaling speed (1.5Gb/s)", /* word 76 bit 1 */
+ "Gen2 signaling speed (3.0Gb/s)", /* word 76 bit 2 */
+ "Gen1 signaling speed (1.5Gb/s)", /* word 76 bit 1 */
"unknown 76[0]" /* word 76 bit 0 */
};
static const char *feat_sata0_str[16] = {
@@ -561,15 +562,19 @@
break;
case 1:
printf("Serial");
- if (subtype & 0xf) {
- if (subtype & 1)
+ if (subtype & 0x2f) {
+ if (subtype & (1<<0))
printf(", ATA8-AST");
- if (subtype & 2)
+ if (subtype & (1<<1))
printf(", SATA 1.0a");
- if (subtype & 4)
+ if (subtype & (1<<2))
printf(", SATA II Extensions");
- if (subtype & 8)
+ if (subtype & (1<<3))
printf(", SATA Rev 2.5");
+ if (subtype & (1<<4))
+ printf(", SATA Rev 2.6");
+ if (subtype & (1<<5))
+ printf(", SATA Rev 3.0");
}
break;
default:
@@ -603,7 +608,7 @@
/* our main() routine: */
void identify (__u16 *id_supplied)
{
-
+ unsigned int sector_bytes = 512;
__u16 val[256], ii, jj, kk;
__u16 like_std = 1, std = 0, min_std = 0xffff;
__u16 dev = NO_DEV, eqpt = NO_DEV;
@@ -877,8 +882,25 @@
printf("\tLBA48 user addressable sectors:%11llu\n", (unsigned long long)bbbig);
}
}
+ if((val[106] & 0xc000) != 0x4000) {
+ printf("\t%-31s %11u bytes\n","Logical/Physical Sector size:", sector_bytes);
+ } else {
+ unsigned int lsize = 256, pfactor = 1;
+ if (val[106] & (1<<13))
+ pfactor = (1 << (val[106] & 0xf));
+ if (val[106] & (1<<12))
+ lsize = (val[118] << 16) | val[117];
+ sector_bytes = 2 * lsize;
+ printf("\t%-31s %11u bytes\n","Logical Sector size:", sector_bytes);
+ printf("\t%-31s %11u bytes\n","Physical Sector size:", sector_bytes * pfactor);
+ if ((val[209] & 0xc000) == 0x4000) {
+ unsigned int offset = val[209] & 0x1fff;
+ printf("\t%-31s %11u bytes\n", "Logical Sector-0 offset:", offset * lsize);
+ }
+ }
if (!bbbig) bbbig = (__u64)(ll>mm ? ll : mm); /* # 512 byte blocks */
if (!bbbig) bbbig = bb;
+ bbbig *= (sector_bytes / 512);
printf("\tdevice size with M = 1024*1024: %11llu MBytes\n", (unsigned long long)(bbbig>>11));
bbbig = (bbbig<<9)/1000000;
printf("\tdevice size with M = 1000*1000: %11llu MBytes ", (unsigned long long)bbbig);
@@ -897,6 +919,38 @@
}
putchar('\n');
+ /* Form factor */
+ if(val[168] && (val[168] & 0xfff8) == 0) {
+ printf("\tForm Factor: ");
+ switch(val[168]) {
+ case 1:
+ printf("5.25 inch");
+ break;
+ case 2:
+ printf("3.5 inch");
+ break;
+ case 3:
+ printf("2.5 inch");
+ break;
+ case 4:
+ printf("1.8 inch");
+ break;
+ case 5:
+ printf("less than 1.8 inch");
+ break;
+ default:
+ printf("unknown (0x%04x]", val[168]);
+ break;
+ }
+ printf("\n");
+ }
+
+ /* Spinning disk or solid state? */
+ if(val[NMRR] == 1)
+ printf("\tNominal Media Rotation Rate: Solid State Device\n");
+ else if(val[NMRR] > 0x401)
+ printf("\tNominal Media Rotation Rate: %u\n", val[NMRR]);
+
/* hw support of commands (capabilities) */
printf("Capabilities:\n");
printf("\t");
@@ -974,7 +1028,7 @@
printf("%u\n",val[SECTOR_XFER_CUR] & SECTOR_XFER);
else printf("?\n");
}
- if((like_std > 3) && (val[CMDS_SUPP_1] & 0x0008)) {
+ if((like_std > 3) && (val[CMDS_SUPP_1] & 0xc008) == 0x4008) {
printf("\tAdvanced power management level: ");
if (val[CMDS_EN_1] & 0x0008)
printf("%u\n", val[ADV_PWR] & 0xff);
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org