openbmc / btbridge

Apache License 2.0
6 stars 9 forks source link

btbridged is very slow #4

Closed causten closed 8 years ago

causten commented 8 years ago

Need to find a way to reduce the lag with ipmi calls. A Barreleye with only 1/2 the dimm slots populated takes over 2 minutes to get past 1 istep in the IPL because each ipmi call takes 1/2 second to perform.

Changing poll(context.fds, TOTAL_FDS, 1000); to poll(context.fds, TOTAL_FDS, 10); Gives me a 33% boost in IPL speed. Maybe the poll loop can be variable, i.e. booting, the poll time would be very short, but then after Petitboot starts we can divert back to a > delay

ChrisAusten: interesting, not surprised but interesting. If everything was working as it should I can't think why you would have observed that speedup right, maybe the timeout isn't really hitting on 1000ms or 10ms. i.e. what does the poll code use as a timer because it is unlikely it is what we are setting it to be ChrisAusten: man 2 poll: Note that the timeout interval will be rounded up to the system clock granularity, ChrisAusten: lowering it to me seems to indicate that someone isn't waking the poll as often as it could be, and the short timeout is doing it for us i could do one more before going to bed. perhaps a -1 that sounds like a bug in our poll implementation (ie, that change should make no difference) jk-: for bt-host? that's what I'm looking for now camb: yep - camb hopes my openbmc/dev remote is good, just updated it... does that include the irq-based bt-host? if not, we should try updating it jk-: looks like no and I'm finding a very suspicious number here in the driver:bt_host->poll_timer.expires += msecs_to_jiffies(500); there is something wrong with the watchdog driver on barreleye, it's not being set up i'll investigate tomorrow using my kernel worked fine on barreleye camb: ah, so we don't have the irq patch? shenki: can we merge that? jk-: yeah nup, at least not in dev branch 0 timeout was a few seconds worse the the 10ms timout ChrisAusten: 0 is going to cause it to go around stupidly fast, defs looks like the problem is the bt-hosts poll... ok, we should try with that in place, and completely remove the poll timeout. you guys need to code something up first? and we can try in 20 hours from now? or you have a driver you can test now? ChrisAusten: we have a patch that shoulds sort it
causten commented 8 years ago

Fixed by moving to an interrupt based environment