1. Summary
  2. Files
  3. Support
  4. Report Spam
  5. Create account
  6. Log in

Changeset 3052

Show
Ignore:
Timestamp:
01/28/10 19:51:24 (3 years ago)
Author:
chrfranke
Message:

Linux: Fix spin-up of SATA drive if '-n standby' is used (ticket #37).

Location:
trunk/smartmontools
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/smartmontools/CHANGELOG

    r3049 r3052  
    4343<DEVELOPERS: ADDITIONS TO THE CHANGE LOG GO JUST BELOW HERE, PLEASE> 
    4444 
     45  [CF] Linux: Fix spin-up of SATA drive if '-n standby' is used 
     46       (ticket #37).  For some reason, this happens if the SCSI/SAT 
     47       device is opened with O_RDWR instead of O_RDONLY. 
     48 
    4549  [CF] Windows: Fix parsing of 'tw_cli' output for 3ware 9.5.x release 
    46        (ticket #43.) 
     50       (ticket #43). 
    4751 
    4852  [CF] Add USB IDs of Seagate FreeAgent Go, Seagate Expansion Portable 
  • trunk/smartmontools/NEWS

    r3051 r3052  
    1616- Fix regression in smartd directive '-l selftest'. 
    1717- Linux: Allow smartd 'DEVICESCAN -d sat'. 
     18- Linux: Fix spin-up of SATA drive if '-n standby' is used. 
    1819- Windows: Fix parsing of 3ware 'tw_cli' output. 
    1920 
  • trunk/smartmontools/os_linux.cpp

    r3042 r3052  
    846846  const char * dev_name, const char * req_type, bool scanning /*= false*/) 
    847847: smart_device(intf, dev_name, "scsi", req_type), 
    848   linux_smart_device(O_RDWR | O_NONBLOCK, O_RDONLY | O_NONBLOCK), 
     848  // If opened with O_RDWR, a SATA disk in standby mode 
     849  // may spin-up after device close(). 
     850  linux_smart_device(O_RDONLY | O_NONBLOCK), 
    849851  m_scanning(scanning) 
    850852{