On 19 March 2015 at 05:09, Doug Anderson <dianders@xxxxxxxxxxxx> wrote: > Ulf, > > On Tue, Mar 17, 2015 at 3:23 AM, Ulf Hansson <ulf.hansson@xxxxxxxxxx> wrote: >>> This will get us within .3V of whatever vmmc is. If vmmc is 3.3V, it >>> will allow vqmmc of 3.0V - 3.6V. >>> >>> This _seems_ sane to me and given any sane system design we should be >>> fine here, I think. I can't see someone designing a system where >>> vqmmc was not within .3V of vmmc, can you? If we think someone will >>> actually build a system where vmmc is 3.3V and vqmmc can't go higher >>> than 2.7V then we'll either need to increase the tolerance here or add >>> a new asymmetric system call like my original patches did. >> >> I know about SoC that supports 3.4V vmmc and 2.9V vqmmc. >> >> What I think we need is the option to have a policy here. We need to >> allow voltage levels stated by the spec and at the same time try chose >> the one best suited. That's not being accomplished here. >> >> Moreover, I wonder whether it's okay (from spec perspective) to have >> vqmmc at a higher voltage level than vmmc. I don't think that's >> allowed, but I might be wrong. > > OK, so sounds like I need to add a regulator_set_voltage_tol2() > function that takes in an upper tolerance and a lower. We can use the > same rough implementation in the core we have today (if Mark is OK > with that) with regulator_set_voltage_tol() but just allow it to be > asymmetric. Agree. Moreover we need that API to also pick the closest value to target, when trying the range "target->minimum". I also believe it would be good to allow both upper and lower limits to be zero. If Mark disagrees with this approach, we will have to deal with all the magic inside the mmc core layer. Very much similar how mmc_regulator_get_ocrmask() is implemented. Kind regards Uffe > > From what I see in the spec for 3.3V cards are supposed to react to a > high signal that is .625 * VDD - VDD + .3 > > > I might not be able to get to this till next week, though... > > -Doug -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html