All of lore.kernel.org
 help / color / mirror / Atom feed
* Use MilliAmps for IPMI tool
@ 2018-12-19 18:57 Shreyas Chandrashekar (shrchand)
  2018-12-19 19:33 ` Tanous, Ed
  0 siblings, 1 reply; 5+ messages in thread
From: Shreyas Chandrashekar (shrchand) @ 2018-12-19 18:57 UTC (permalink / raw)
  To: openbmc; +Cc: Guhan Balasubramanian (gubalasu)

[-- Attachment #1: Type: text/plain, Size: 498 bytes --]

Hi,

IPMI tool is being used to probe and get the various sensor values from bmc. However, after reading through the IPMI spec there is no support for milliAmperes or milliVolts. Is there any way to have the support for millAmps and milliVolts?

The alarms are raised based on increments in mAmps/mVolts. Hence would prefer the values sent across as in mAmps (as opposed to dividing the value by 1000 to convert them to Amps).

Any help would be appreciated.


Regards

Thanks
Shreyas

[-- Attachment #2: Type: text/html, Size: 2854 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: Use MilliAmps for IPMI tool
  2018-12-19 18:57 Use MilliAmps for IPMI tool Shreyas Chandrashekar (shrchand)
@ 2018-12-19 19:33 ` Tanous, Ed
  2018-12-20  0:44   ` Shreyas Chandrashekar (shrchand)
  0 siblings, 1 reply; 5+ messages in thread
From: Tanous, Ed @ 2018-12-19 19:33 UTC (permalink / raw)
  To: Shreyas Chandrashekar (shrchand), openbmc
  Cc: Guhan Balasubramanian (gubalasu)

>IPMI tool is being used to probe and get the various sensor values from bmc. However, after reading through the IPMI spec there is no support for milliAmperes or milliVolts.
 
I'm not really sure how to came to this conclusion.  Yes, there is no "milliamp" unit in the unit codes table, but I wouldn't expect there to be given how IPMI sensor scaling works.  For linear scaling mode (which is all openbmc supports today) value scaling is set by M and B values in a type 1 SDR record.  Setting an M value of 1000 and a units flag of Volts would effectively give you "millivolts" resolution.

Another option here would be to use logarithmic scaling, which would give you better resolution in the lower end of the spectrum (especially useful in the case of millivolts).  If this is something you'd like to pursue, there's likely some people on this list that could point you to where that capability could be added.

Some sections of the IPMI spec to reference for the above

36.3 Sensor Reading Conversion Formula
36.4.2 Resolution.
43.1 SDR Type 01h, Full sensor record, bytes 25:28

There has been some effort made to make these values calculated automatically based on the maximum and minimum value readings in the DBus interface, which makes this process far less error prone.  If this kind of thing is important to you, I would highly recommend reviewing and adding your opinion to those patches.

-Ed

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Use MilliAmps for IPMI tool
  2018-12-19 19:33 ` Tanous, Ed
@ 2018-12-20  0:44   ` Shreyas Chandrashekar (shrchand)
  2018-12-20  1:01     ` Tanous, Ed
  0 siblings, 1 reply; 5+ messages in thread
From: Shreyas Chandrashekar (shrchand) @ 2018-12-20  0:44 UTC (permalink / raw)
  To: Tanous, Ed, openbmc; +Cc: Guhan Balasubramanian (gubalasu)

Ed,

Thanks for the response. 
Agreed, we can set the value of M and B to have the values give us milliamp and millivolts resolution. Will look into this more closely.

We are looking at having milliamp and millivolts units in the unit code table. Is there anyway to get that support? That way, we will be able to display the values in millivolts and milliamps.

Regards

Thanks
Shreyas

On 12/19/18, 11:33 AM, "Tanous, Ed" <ed.tanous@intel.com> wrote:

    >IPMI tool is being used to probe and get the various sensor values from bmc. However, after reading through the IPMI spec there is no support for milliAmperes or milliVolts.
     
    I'm not really sure how to came to this conclusion.  Yes, there is no "milliamp" unit in the unit codes table, but I wouldn't expect there to be given how IPMI sensor scaling works.  For linear scaling mode (which is all openbmc supports today) value scaling is set by M and B values in a type 1 SDR record.  Setting an M value of 1000 and a units flag of Volts would effectively give you "millivolts" resolution.
    
    Another option here would be to use logarithmic scaling, which would give you better resolution in the lower end of the spectrum (especially useful in the case of millivolts).  If this is something you'd like to pursue, there's likely some people on this list that could point you to where that capability could be added.
    
    Some sections of the IPMI spec to reference for the above
    
    36.3 Sensor Reading Conversion Formula
    36.4.2 Resolution.
    43.1 SDR Type 01h, Full sensor record, bytes 25:28
    
    There has been some effort made to make these values calculated automatically based on the maximum and minimum value readings in the DBus interface, which makes this process far less error prone.  If this kind of thing is important to you, I would highly recommend reviewing and adding your opinion to those patches.
    
    -Ed
    


^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: Use MilliAmps for IPMI tool
  2018-12-20  0:44   ` Shreyas Chandrashekar (shrchand)
@ 2018-12-20  1:01     ` Tanous, Ed
  2018-12-20 18:07       ` Shreyas Chandrashekar (shrchand)
  0 siblings, 1 reply; 5+ messages in thread
From: Tanous, Ed @ 2018-12-20  1:01 UTC (permalink / raw)
  To: Shreyas Chandrashekar (shrchand), openbmc
  Cc: Guhan Balasubramanian (gubalasu)

> 
> We are looking at having milliamp and millivolts units in the unit code table. Is
> there anyway to get that support? That way, we will be able to display the
> values in millivolts and milliamps.
> 

What problem are you trying to solve with that change?  The IPMI spec is more rigid than it once was, and for a use case that is already covered, I would be surprised if you could get it added, and get all the tools and bindings to add support.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Use MilliAmps for IPMI tool
  2018-12-20  1:01     ` Tanous, Ed
@ 2018-12-20 18:07       ` Shreyas Chandrashekar (shrchand)
  0 siblings, 0 replies; 5+ messages in thread
From: Shreyas Chandrashekar (shrchand) @ 2018-12-20 18:07 UTC (permalink / raw)
  To: Tanous, Ed, openbmc; +Cc: Guhan Balasubramanian (gubalasu)

As I mentioned, we have all the readings in milliamps/millivolts by default. And the consumer of the IPMI tool makes all the calculations based on milliamps since that is the unit of the readings. We were wondering if there was a way to have milliamp/millivolts in the unit code table it would be consistent. 
If not, we will just go with changing them to Amps and do the changes accordingly.

Thanks a lot for the responses Ed. Appreciate it!


Regards

Shreyas 
On 12/19/18, 5:01 PM, "Tanous, Ed" <ed.tanous@intel.com> wrote:

    > 
    > We are looking at having milliamp and millivolts units in the unit code table. Is
    > there anyway to get that support? That way, we will be able to display the
    > values in millivolts and milliamps.
    > 
    
    What problem are you trying to solve with that change?  The IPMI spec is more rigid than it once was, and for a use case that is already covered, I would be surprised if you could get it added, and get all the tools and bindings to add support.
    


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-12-20 18:07 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-19 18:57 Use MilliAmps for IPMI tool Shreyas Chandrashekar (shrchand)
2018-12-19 19:33 ` Tanous, Ed
2018-12-20  0:44   ` Shreyas Chandrashekar (shrchand)
2018-12-20  1:01     ` Tanous, Ed
2018-12-20 18:07       ` Shreyas Chandrashekar (shrchand)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.