* If CF Timing mode is specified, treat it as SSD
(some SD adapters don't report CFA supported but but report this,
and _all_ microdrives seen do not report this)
* If CFA compliant and CF power level 0, treat as SSD
Change-Id: Ia8c88b4636af9bae75fbd1c253d8b2b01bca6584
The SSD detection heuristic is flawed, and when it fails
(due to very crappy CF->SD adapters) we end up corrupting things.
So let's give up a slight amount of performance on the original hard
drives (which are aging out anyway) in favor of guaranteeing safety.
Change-Id: Id92583a6b9ae6ec543b91b3e0f8f28b57ac38cb0
* hostfs_removeable()/present() needed IF_MDVOID() in their prototypes
* SIM_EXT_INSERTED/EXTRACTED are gated by HAVE_HOTSWAP
Change-Id: Id8c688f3538db99586a4f5062c83466374451883
* xDuoo X3 fix some warnings due to an incorrect #ifdef
* stub storage_removeable() and storage_present() for non-HOTSWAP builds
* sim_trigger_external() is gated by HOTSWAP, not MULTIDRIVE
Change-Id: I38f14fdfeba13957899c378051d49afc2e8245e5
Multivolume support is only necessary if mounting multiple volumes
simultaneously, which the bootloader won't do.
Change-Id: I725061dd2aa47abe7652b0d27258dd3af821c913
Notably:
* double-paste in ihifi760 config.h
* jz4740 ATA & SD drivers used MULTIVOLUME instead of MULTIDRIVE
* Simulators implicitly rely on HAVE_HOTSWAP
Change-Id: I44fc7f98f0f6df366f016567c330f87e9f3ca6a6
* HAVE_MULTIDRIVE implies HAVE_MULTIVOLUME as the latter is always
removeable storage
* SD storage implies MULTIVOLUME
* ATA storage (with HAVE_LBA48) implies MULTIVOLUME
* Replace HAVE_MULTIDRIVE && NUM_DRIVES == 1 with HAVE_MULTIVOLUME
Since SD and ATA can exceed 2TB, we need multiple volumes to fully
utilize available storage with FAT32.
In practice I believe this only affects the ipod devices.
Change-Id: Ia597770948b0e2b47630f7264ad34f225a33a640
* Query variable info _before_ mmaping the framebuffer
* Sanity-check the resolution/bitdepth, and if it doens't match
try to set it to what we want.
This is functionally a no-op.
Change-Id: I087ff81775d8f63bf7846b7fef19f6fc36c1cc84
* Distinct error codes for all failures
* Corrected some comments and error messages
The ypr0/r1 target should be switched over to the generic lcd-linuxfb
driver, but that will come later.
Change-Id: Idc3867a96db7e431847473708712f88dd2725a96
set_features() returns an error between -1 and -39, so make sure
every caller adds -60 to that so no matter where an error is printed
the value is consistent.
Change-Id: Ic81108ee70a2cb5ff7ea2445f086420fe850d07e
Status:
- tested on:
Samsung YH920 - it uses this detection too, it always should have
the radio.
Samsung YH925 with the radio.
- untested on:
Samsung YH925 without the radio.
Change-Id: I68b39c09d6b7e26a4c373fbd8bf9401a97e86123
On PortalPlayer iPods, it looks like the serial number is available in a
specific memory location. When adding support for Samsung S5L87xx-based
iPods, this algorithm has not been limited to PP-only, so it sets the
serial number USB descriptor to random memory data.
With this change, it will use the ATA HDD serial number on iPod 6G. On
Nano 2G it won't provide a serial number at all.
Change-Id: I53d48915d629dbd87b2dbbcba5f228ca5949fa9b
This should actually be strip_extra_leading_separators() but
its not used anywhere else yet and I don't see enough callers
in core to make it worth the extra overhead
Change-Id: Icdd292869b4198bed7725c51820f6b2111ad739d
Some CF cards claim to support Advanced Power Management, but error
out when the command is issued. There is a special case in the
code that ignored errors when issuing the APM command, but was referenced
against a specific index in the feature table.
When the tagle was reorganized, the index was wrong depending
on if ATA_DMA was enabled or not.
The fix is to test against the specific subcommand ID instead of the
table index.
Change-Id: I2ef7a05b2d70675c38e41d70b5189b394056cb74
technically this isn't currently causing any issue but
coverity correctly identified the potential for buffer ovfl
Change-Id: I4af462c9860c44f22d05b5b2b4c685364823d395
it appears this is false positive but its compliaining
about the uninitialized pointer,
not a bad idea to initialize pointers to NULL anyway
Change-Id: I5832a19ab13971c7d55580694eef70591a3a9acb
BYTES2INT16() uses [i + 0] and [i + 1] therefore 30 is the max element
available in the raw byte array of size 32
(((uint32_t)array[pos+0] << 0) | \
((uint32_t)array[pos+1] << 8))
struct /* raw byte array */
{
uint8_t data[32];
};
basisname is only uninitialized in the . and .. dir entries
both are likely false positives but cheap enough to guard against
Change-Id: Iab3d186fed6050d2d61185071765a2c0feb9515f
mode only goes 0-4 the original commit mixed up the index and mode
bad stuff must happen but its been here for 16 years
Change-Id: I7e69f4e2574029a6bc3cea76e8803d2d0357d9e2
In verbose mode it will log valid the strings found, otherwise it will
only complain when we encounter a missing string.
Unfortunately a missing string is not inherently a problem, due to
conditional expressions. So all we can do is complain in checkwps
or if wps debugging is turned on.
Meanwhile, this is the first step in actually enumerating the translated
strings used by themes.
Change-Id: Ia93b333085e825d5b085c4d372ad8e13aa3e3ba1
Hopefully this should cover our bases so we can change
the behavior of the stereo switch to keep line out working
when they change the hardware on us!
Change-Id: Ic36bcb3778d5681a5f3f158c689df9c1420c1d7e
Annoyingly, this makes all of the '.S' files we compile get treated as
divided syntax, so we need to make the syntax in them explicit.
Change-Id: I56a3916b7b24c84a1214a5d6bc4ed4d651f002cf
This reverts commit 0c737d3b2e.
Reason for revert: Not really a concern as open_stream returns an independent buffer since g#566
Change-Id: Idbd2f4a7cc2ea6362b7714629469eeb7b3d19b3b
Additionally, synchronize with the standard ATA driver's feature table
* Acoustic management set to quietest
* Set power mode to lowest w/o standby
Change-Id: I12e64354d4c946228e9a55fc8da2114127d08d28
...by checking to see if the mandatory ATA PM feature flag is set
The common CF->SD adapters don't report this.
TODO: When PM is not available, issue a CMD_FLUSH[_EXT] instead?
Change-Id: If9200bd3c03a984376203aeea4fbe11e230a9b4d
It is likely that these things accept data far faster than the spinning
rust drives ever would, and while there is a question about PIO timings,
DMA timings seem to be solid.
Change-Id: I70644e0ad85a6ed429c8704e66ca7af91d78765c
* Use of ata_disk_can_poweroff() was inverted, resulting in SATA SSDs
getting powered off but leaving _everything_ else on, including spinning
rust!
* Replace the can_poweroff() heuristic with a test for the mandatory
ATA power mgmt feature flag. Notably, the CF->SD adapters don't claim
to support this!
* Eliminate duplicated tests in sleep code
* Wrap all poweroff-related code with HAVE_ATA_POWER_OFF
* Don't ever use SLEEP command, only STANDBY_IMMEDIATE
* Gate call to STANDBY_IMMEDIATE behind a can_poweroff() test
* Prefer FLUSH_CACHE_EXT to FLUSH_CACHE where available.
* Improve SSD detection heuristics to any of these:
* Explicltly identifies as SSD (covers newer CF and SATA)
* TRIM support
* CFA compliant AND (CF level 0 OR high speed support)
* Report SSD detection in debug menu
Change-Id: I7fcb83b6d6eabddc11c64326a573b08ab85412b5