/srv/irclogs.ubuntu.com/2013/11/15/#ubuntu-kernel.txt

=== steve__ is now known as sbeattie
=== gfrog_ is now known as gfrog
=== AceLan_ is now known as AceLan
apwhallyn_, heh you should indeed11:03
=== fmasi_afk is now known as fmasi
alex116hi, I'm trying to read i2c data and from userspace the example code uses ioctl13:05
alex116I want to read i2c data from a kernel module and would like to figure out how to read from the device13:06
alex116can I just use the normal open read write close functions?13:06
ckingalex116, how about https://www.kernel.org/doc/Documentation/i2c/dev-interface13:12
=== kentb is now known as kentb-afk
=== fmasi is now known as fmasi_afk
ckingmaybe https://www.kernel.org/doc/Documentation/i2c/writing-clients13:35
=== fmasi_afk is now known as fmasi
alex116I was hoping I could just use the loaded driver's functions because thats all ioctl does14:10
igalicCan I somehow make it impossible (or near impossible) for apt to even consider removing linux-image-server, linux-server, linux-headers-server, etc..?14:41
infinityzequence: It's SRU time again, if you missed out on the new bugs.14:44
infinityigalic: There's no reason it would remove them unless you ask it to remove something they depend on.14:44
infinityigalic: As a general rule, people are expected to read apt's output when it tells them what it intends to do.14:44
apwinfinity, arn't they even manually installed top levels so it should be hard to force them off14:45
apwigalic, how did you get into a sitruation where it wanted to, what did you ask for14:46
apwthat it though could only be solved by so removing it14:46
infinityapw: They're manually installed, yeah.  Not that autoremove would ever pull them anyway, since they're never installed as deps.14:47
infinityapw: So, people removing them are doing it intentionally (ie: by removing the kernel they depend on)14:47
apwi can only assume you asked it to remove the latest kernel ?14:47
igalicWe're trying to remove automatically installed kernels. We don't quite trust autoremove, since it tends to uninstall things that are "running". This "recipie" http://dpaste.com/1464493/  (from https://help.ubuntu.com/community/Lubuntu/Documentation/RemoveOldKernels ) however will remove /other/ stuff that we'd rather kept.14:47
igalic(I like how the automatic section is actually empty)14:48
igalicoh.. that's the latest kernel. That's why it's removing it.14:51
igalicso that "documentation" is lying.14:52
diwicogasawara, I understand you will discuss this next week, but do you today have a feeling for whether you'll end up with 3.13 or 3.14 for the LTS?14:53
ogasawaradiwic: most likely 3.1314:54
diwicogasawara, thanks, that was my guess too14:54
rtgapw, dropped 'UBUNTU: SAUCE: (no-up) drm -- stop early access to drm devices' during the rebase. Do you think we still need it ?14:56
=== fmasi is now known as fmasi_afk
infinityigalic: "apt-get autoremove" will not remove the running kernel.  Random other weird snippets on wikis are generally suspect.15:01
igalicinfinity: apt-get autoremove will not remove the running kernel, but it will remove the running kernel's utils, tools and headers.15:02
infinityigalic: Not anymore.15:02
apwrtg, i think i am supprised to still find it applied, i thought that that was fixed another way in upstream now15:02
rtgapw, well, I've been faithfully forward porting it for several releases15:03
infinityigalic: That was fixed in saucy.  In precise, it'll yank tools probably, yeah.  Maybe also headers.15:03
apwrtg, hehe ... oh well ... 15:03
apwinfinity, didn't we fix those deps back in the end?  i thought we did15:03
rtgapw, guess we'll find out. I haven't even boot tested this pile yet15:03
igalicinfinity: that's badd, because we're running LTS15:04
infinityapw: I may have made the header fix in precise.  Can't fix the tools issue without backporting the rename/reorg.15:04
igalicinfinity: can you link me to the bug?15:04
=== kentb-afk is now known as kentb
apwinfinity, point, that we have done for the lts-backport kernels, saucy onwards but .. yes not before that15:04
infinityigalic: Okay, just verified, precise won't autoremove headers, but it will autoremove tools.15:05
=== fmasi_afk is now known as fmasi
infinityigalic: And the tools problem is hard to solve without us reorganizing the precise kernel packages.15:05
infinity(Which is probably not worth doing with another LTS around the corner, IMO)15:05
infinityGiven that the number of people who need tools installed is tiny.15:05
igalicperf top is invaluable.15:06
infinityFor normal users?15:06
igalic>_o15:07
infinityYou and I may define normal differently. :P15:07
igalicDefine normal users.15:07
infinitys/normal/average/15:07
infinityStatistically, very few people use perf.15:07
igalicI'm a Unix Admin. I don't know what you mean.15:07
infinityAnd the people who do use it probably intersects well with people who can read the output of "apt-get autoremove" and say "no" when it's not what they want.15:07
igalicYes, except we have everything puppetized on hundreds of machines.15:08
infinityAnyhow, we *could* backport the whole tool renaming madness to precise, I'm just not sure it's worth the pain.15:08
igalicinfinity: if I run the cool new kernels on LTS, will that still be an issue?15:09
infinityapw: Is the tool renaming magic represented in linux-lts-saucy?15:10
igalici.e.: linux-image-generic-lts-saucy 15:10
* infinity looks.15:10
igalic(or any other)15:10
apwinfinity, yes15:10
infinityYeah, looks like that works.15:10
apwinfinity, oh well ... perhaps the answer is "in the new one"15:11
infinityigalic: Only lts-saucy, not the earlier ones.15:11
infinityBut, I'd need to backport the matching apt fix for that.15:11
apwit may not have hit updates yet, or is about to now or something15:11
igalicinfinity: apw: can you link me to the issues describing this?15:11
infinitylinux-tools-3.11.0-12-generic linux-tools-3.11.0-13-generic linux-tools-3.11.0-14-generic are all what I'd expect in precise.15:11
infinityhttps://bugs.launchpad.net/ubuntu/+source/linux/+bug/120528415:12
ubot2Launchpad bug 1205284 in linux (Ubuntu Precise) "linux-tools naming is not scalable to multiple source packages" [Medium,Fix committed]15:12
apwinfinity, the bits for master might not be in yet, and there is a common tools package fix pending on the lts-saucy branch15:12
apwinfinity, yeah the wrapper fixes are pending for the next sru round for master15:13
infinityapw: s/next/current/, or in another month?15:13
apwas in only on master-next right now15:13
infinityBummer.  Well, I'll backport the apt fix, since that's trivial.15:14
apwie the /usr/bin/perf won't recognise the new perf binaries till that fgoes out15:14
apwyeah, it got missed in testing15:14
apwits not like you cannot find them manually so not world ending, they are there installed15:14
infinityapw: Alright, apt backport uploaded.15:18
igalicwowzers!15:18
infinityapw: If someone wants to mangle all the tools crap in 3.2, that might make somoene happy, but I personally think it's likely not worth the effort.15:19
igalicinfinity: do you have a bug for that also I can track?15:19
infinityigalic: Same bug I pasted above.15:19
igalicso, once this gets promoted (demoted?) to precise, if we have linux-image-generic-lts-saucy installed, and the system's apt-to-date, we can simply have Unattended-Upgrade::Remove-Unused-Dependencies "true"; and everything will be perfectly fine.15:23
ppisatibjf: i'm preparing the P/omap4 kernel15:25
bjfppisati, ack15:25
* ppisati disappears for a bit15:28
infinityigalic: If you want headers too, that would be linux-generic-lts-saucy15:30
infinityigalic: And linux-tools-generic-lts-saucy for tools.15:30
igalicinfinity: linux-generic-lts-saucy installs headers also?15:30
infinityigalic: "linux-generic" depends on "linux-image-generic" and "linux-headers-generic" (trade "generic" for flavour du jour, like generic-lts-saucy)15:31
igalicinfinity: I think I've asked this question a couple of times, but, what's the difference between -generic, -server, -chewgum, -etc ?15:31
infinityigalic: These days, generic is the only flavour, though there's a fake not-quite-flavour called virtual, which is actually just generic without most of the modules.15:32
infinityigalic: But, on LTSes, you'll have different generic options for the HWE backport kernels (like lts-raring, lts-saucy, etc).15:33
infinityOh, I guess it's not fair to say "generic" is the only one, as there's also lowlatency.15:33
infinityBut it's the only one built from the master sources. :P15:33
igalicWhat's that mean?15:34
infinityThere's a "linux" source package, maintained by the Canonical kernel team, and it only produces the generic (and virtual) flavour.15:35
apw(and notionally the server flavour)15:35
infinitylowlatency is a rebased fork maintained by the Ubuntustudio team, which has a few different twiddles.  Not particularly ideal for servers, so probably of little intrerest to you.15:35
infinityapw: There is no server flavour.15:35
infinity(Not anymore)15:36
apwthere is a linux-server and linux-{image,headers}-server though15:36
apwwhich are used in server images, which is why it is notional15:36
infinityapw: Sure, but it just installs generic. ;)15:37
apwright, just .. dunoo ... being a pedant15:37
infinityI suppose it keeps the option open if we feel the need to fork configs again some day.15:37
infinityBut with scheduler improvements and the like, forked configs are less interesting over time.15:37
igalicIt would be nice to install -server and have sysctl settings actually worthy of a server.15:37
apwigalic, that would be possible, as it has its own meta package15:38
apwigalic, if there was a definative set which made sense15:38
igalicapw: disabling the oom killer for instance ;)15:43
apwigalic, i don't think disabling that is going to solve any issues, yo should never ben runnig a server to the point it would need to15:45
infinityDisabling the OOM killer doesn't magically prevent you from running out of RAM.15:49
infinityIt does, on the other hand, assume that the first few processes started are the only ones allowed to have memory leaks, which might be a desired behaviour for some.15:50
igalicNo, it doesn't but it magically prevents the kernel from not killing processes even though I'm NOT out of RAM.15:50
infinityigalic: When you're out of RAM, all your processes are out of RAM.  Until a sufficiently large one crashes.  *shrug*15:51
infinityThe OOM killer attempts to make intelligent decisions based on usage patterns.  It's not necessarily any dumber than the non-oom-kill algorithm of "let stuff crash when it tries to malloc()".15:51
infinityigalic: Without the OOM killer, you could leak with some Java servlet, but the malloc() that hits the brick wall could be init.  Instant kernel panic, game over.15:52
infinityigalic: You can't control WHICH process hits the last available page and dies.15:53
igalicplease read http://www.twistedmatrix.com/users/glyph/rant/softethics.html15:53
apwyour point with that ?15:54
apwor is that a total no-sequiter15:54
infinityapw: It's unethical to prevent init(8) from dying, if that's what it chose to do.15:54
infinityapw: How dare we stand in the way of its suicide attempt via malloc().15:55
apwigalic, anyhow if you can change it via sysclt, one can do that, so ...15:55
igalicapw: read the bit about car manufacturers.15:57
igalic(I think a good resource is also http://www.loper-os.org/?p=284 )15:59
infinityigalic: It's a poor analogy, in reference to the above discussion.  If your car runs out of gas, do you think it would be appropriate for it to jam a piston through the hood and send a tire flying off the side of the road?15:59
infinityigalic: Sure, if you had just kept the tank topped up, you'd be a responsible driver, and you'd still have an engine.  On the other hand, lolwut?16:00
igalicI think a better "fuel" analogy is this one https://lwn.net/Articles/104179/ ;)16:01
apwso all one needs to do is swtich to full commit mode for allocation and ensure you have enough swap16:03
igalicAnd suddenly you have a predictable VM. YAY. It's almost like I'm using a Unix.16:04
apwyeha right, like they wern't the same16:06
=== fmasi is now known as fmasi_afk
=== fmasi_afk is now known as fmasi
ppisatirtg: i'm building a test kernel17:09
rtgppisati, ack, I'm about to email a comment to robher about the mac learning patch17:10
TooLmaNHi guys.  I'm back to working on embedded projects and I'm rusty on kernel building.  What is a good resource for building a kernel from source on Ubuntu/Mint?  The Wiki appears to be a bit dated.  Thanks17:12
ppisati[flag@luxor ubuntu-saucy]$ git fetch origin17:16
ppisati[flag@luxor ubuntu-saucy]$ git rhard origin/master-next17:16
ppisatiHEAD is now at a223125 UBUNTU: SAUCE: (no-up) apparmor: Fix tasks not subject to, reloaded policy17:16
ppisati[flag@luxor ubuntu-saucy]$ git cherry-pick -sx f0915781bd5edf78b1154e61efe962dc15872d0917:16
ppisati[master-next 15fa8df] ARM: tlb: don't perform inner-shareable invalidation for local TLB ops Author: Will Deacon <will.deacon@arm.com> 3 files changed, 123 insertions(+), 30 deletions(-)17:16
ppisatirtg: ^17:16
ppisatirhard is an alias for 'reset --hard'17:16
rtgppisati, huh, well maybe I fat fingered something.17:17
ppisatirtg: actually that hash comes from rmk's git tree17:17
rtgppisati, well, try the same patch from Linus' tree17:18
ppisatirtg: but if you don't have that remote, it would probably say 'unknown hash or something'17:18
ppisatirtg: let's see17:18
TooLmaNdisregard.  I had to add the source repos.  17:21
ppisatirtg: even linus version apply ok17:22
ppisati[flag@luxor ubuntu-saucy]$ git cherry-pick -sx f09157817:22
ppisati[master-next acaa3ca] ARM: tlb: don't perform inner-shareable invalidation for local TLB ops Author: Will Deacon <will.deacon@arm.com> 3 files changed, 123 insertions(+), 30 deletions(-)17:22
rtgppisati, ok, works for me then17:22
ppisatianyhow17:22
ppisatilet's wait until it builds17:22
rtgppisati, isn't that the same SHA1 as rmk tree ? f091578 and f0915781bd5edf78b1154e61efe962dc15872d0917:23
ppisatisame sha17:23
rtgppisati, ok, I see what I did. I got the wrong patch, e.g., 'ARM: tlb: don't perform inner-shareable invalidation for local BP'17:24
ppisatirtg: yeah, slightly different subj17:24
ppisatirtg: local BP vs local TLB17:24
rtgppisati, too damn close...17:24
=== fmasi is now known as fmasi_afk
=== fmasi_afk is now known as fmasi
ppisatirtg: sent18:10
rtgppisati, ack18:10
=== fmasi is now known as fmasi_afk
slangasekapw: hey, can you sanity check me... does fsync() have any meaning on ptys?20:54
apwslangasek, i cannot think what it would mean on a pty21:01
slangasekhmm21:01
apwthe data is either in the hole or it is not21:01
slangasekso I'm asking because of https://jenkins.qa.ubuntu.com/view/Trusty/view/AutoPkgTest/job/trusty-adt-upstart/14/ARCH=amd64,label=adt/ - an upstart test that's failed intermittently, because a log file that's supposed to be created didn't get created21:02
slangasekand I'm trying to figure out why; my current guess is in-kernel buffering21:02
slangasekbut that's a SWAG21:03
slangasekthe other possibility is the kernel is doing everything right, and upstart is just failing to create the logfile with the data it's meant to be reading from the pty ;)21:03
apwslangasek, if you can point me at the source for the test, i'll have a think about it and figure out if fsync means anything21:08
slangasekapw: http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/trusty/upstart/trusty/view/head:/init/tests/test_state.c#L2115 vs. http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/trusty/upstart/trusty/view/head:/init/tests/test_state.c#L214321:10
slangasekanyway, fsync() returns non-zero, so in practice that's the wrong interface anyway ;)21:12
* rtg -> EOW22:04

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!