/srv/irclogs.ubuntu.com/2012/05/07/#ubuntustudio-devel.txt

ailoThis is the patch for threadirqs https://lkml.org/lkml/2011/2/23/51300:33
len-dtailo,  I didn't think we were running a 2.6 kernel.. I guess we were at the time.00:38
ailolen-dt: Linus changed how the versioning is done after 2.6.39. In a way, the 3.x.x kernels are 2.6 kernels00:41
TheMusoailo: No I don't know.00:42
ailoTheMuso: Thanks. Are very occupied in the coming future? I was thinking about maybe starting to document the kernel maintenance bit. At least it would be really helpful for me to get an idea of your current steps to update it00:44
ailoI mean to ask, are you very occupied in the coming future. Didn't realize I was leaking words00:44
ailolen-dt: Also, the threadirqs option was included with 2.6.39, if I remember correctly. Either that, or the version before00:46
TheMusoailo: Its UDS this week, so will be flat out with that, probably not till I return, eta Monday week.00:46
ailoTheMuso: Ah, right. Well, I'm not in any particular hurry, so whenever you can is fine with me00:47
TheMusoOk no problem.00:47
len-dtOK, ailo the network-manager is another of those respawn things.00:47
ailolen-dt: How's your skill in reading C?00:54
len-dtIt has been a number of years to honest. No real training, just read the part of the book needed for the next project ;-)00:55
len-dtailo, what would you like me to look at?00:55
ailoI'm looking at the kernel patch. Unfortunately, I don't read C very well. Trying to figure out where the threadirq function is defined, or whatever, and where it in that case could be enabled without having to add a boot option00:56
ailolen-dt: I pasted the patch here http://paste.ubuntu.com/972612/00:56
ailoThe interesting part I guess starts at around line 87 .. linux-2.6-tip/kernel/irq/manage.c00:58
len-dtailo, I had just sort of figured that out..00:59
ailolen-dt: I was just reading a comment there, which talks about some buses being slow, like maybe the irq for your network card01:02
ailoIt's a little frustrating not having a good picture of the whole. I really should go to school and study these things01:03
len-dtailo, I'm a bit old for that ;-) I've had enough school forever...01:04
len-dtailo, it has to be the bit at the begining of manage.c (lines 95 to 105)01:19
len-dtTo really tell I would have to know the way the kernel deals with CL parameters.01:20
len-dtailo it seems to be a call to early_param()01:24
ailolen-dt: I think this might have to do with it too, lines 155,15601:24
ailo sched_setscheduler(current, SCHED_FIFO, &param);01:24
ailo current->irqaction = action;01:24
ailoWondering about &param particularly01:24
ailoBut then, I don't really know what I'm reading01:24
ailoSCHED_FIFO is important at least http://lwn.net/Articles/296419/01:26
len-dtPart of the problem is that the rest of the file is missing. It would be best to look at manage.c with the patch added. It would add context to things01:26
ailolen-dt: I suppose you are right01:29
ailoStill, the part which makes threadirqs option readable is in that patch01:29
len-dtYes. but what it does with it is not.... maybe...01:31
ailoWell, it's always interesting to learn half a story of something new :P. I'm hoping someone will pick up on the subject on LAD and explain how the threadirq option can be added into the source.01:38
ailoNow it's time to go to bed!01:38
len-dtQasMixer has some nice features over the xfce mixer for setting levels while using jack.02:17
ailolen-dt: Well, it seems there is a way to add boot arguments to the source, without the need to hard code it. It can be done adding the argument to /arch/<arch>/Kconfig under a couple of places, but I don't think this is how -lowlatency does it10:44
ailolen-dt: I started a discussion about the rtirq script on LAD12:47
ailohttp://lists.linuxaudio.org/pipermail/linux-audio-user/2012-May/084809.html12:47
ailoLAU, I mean12:47
ailoAnyway, I really want to get to the bottom with this12:47
ailoYou have your NM causing problems in spite of the rtirq script12:47
ailoI want to know if we can make your problem go away without stopping NM12:48
ailolen-dt: Also, about the threadirq, it can be passed as a kernel config option argument. Just trying it now12:55
len-dt ailo hi, just woke up. I am certainly willing to try things. My netbook is about the worst HW likely to be used for audio.14:11
len-dtailo, there is probably slower HW around, but this is about as anti-audio as they get ;-)14:20
ailolen-dt: Sounds like a perfect machine for testing then14:22
ailoOne thing I realized I haven't really tried is running stuff without realtime privilege, to see what the difference is14:23
len-dtailo, I figure so. I played with recording using the internal audio IF and an external (cheap) mixer.14:24
len-dtI turned the internal card way down (mic boost off) and the mixer as high as I could with out clipping.14:25
len-dtI used a dynamic mic (no phantom power) with an xlr to phone jack adaptor.14:26
ailoRunning jackd without privileges on -lowlatency is sort of like running jackd with privileges on -generic14:28
ailoWorking pretty decently at -p 12814:28
len-dtI was able to record quite a quiet stuff. It is not studio quality for sure, but good enough pod caste for example.14:28
ailoAllthough, I believe -generic is worse14:29
ailolen-dt: Not bad :P14:29
len-dt-p 128 is the lowest jack will even start at on my netbook14:29
ailoI'm more and more thinking that when it comes to system configuration, only the kernel and privileges are absolutely needed. And that the rest is very hardware dependant. Perhaps solvable by hacking the kernel14:31
ailoIt would be nice if the kernel could be easily made more audio friendly, either by patching the vanilla source, or by adding ways to tune the kernel easily either during boot, or runtime14:32
ailoBy patching I mean making it permanent for all kernels that derive from the vanilla kernel14:34
ailoI don't see why we need to shut things off in order to get rid of xruns14:35
ailoIf audio is prio, then it should be able to make it prio more easily14:35
len-dtailo, sorry, I was helping someone on the other channel connect a midi keyboard to qsynth.14:47
len-dtailo, I think part of my problem may be the wlan driver.14:48
len-dtI'm not sure how unless the irq top half has more in it than it should.14:51
len-dtThere may also be internal bus issues.14:59
len-dtailo, the netbook is all about doing things with the least. I wonder if the wlan chip(set) uses system bus for some things. So NM tells wlan to scan and waits for irq when done, but wlan uses system bus while scanning preempting the cpu for a short time.15:44
len-dtI do know the video chip uses system bus, but it knows how to interleave better.15:44
ailolen-dt: Perhaps it is a driver issue then, and that the wlan is being rude by taking up too much time, or something? But, how do drivers work? Aren't they limited by something else in the kernel, or can you really create havoc for realtime applications with badly written drivers15:46
ailoIf it is driver specific, then all hardware using that drivers could have the same issue15:47
ailoAnd in that case it's a matter of doing something to the driver, which is probably not open source15:47
len-dtailo, the driver is supposed to be divided into top half and bottom half. the Top half is supposed to answer/reset the interupt and call the bottom half.15:48
len-dtIf the top half does too much that would be a problem.15:48
len-dtThe netbooks share a lot of stuff. It may even be that the wlan chip and the sound chip share things too.15:49
len-dtailo, it will be interesting to see how my USB audio IF handles things.15:50
ailoI'm not sure I got the right picture, but I'm guessing it's something like this. The bottom half is either activated by whatever it is physically connected to, and since it doesn't have it's own way of storing a lot of the data coming through, it will want to pass that on to the top half, which in turn tells the kernel it is ready to send it's data, no?15:53
ailoEither activated by that, or the top half which wants to send info out..15:53
ailoIt seems to me the problem is not in managing what is coming to the device, but in how network-manager handles it15:54
ailoAnd that the kernel allows network-manager to do something odd15:57
ailoOr, allowing the wlan device to execute a number of tasks in que instead of breaking it up15:58
ailoI'm being unclear as usual. I need to start reading about this stuff. Never been interested in drivers, hardware and that sort of things before16:03
ailolen-dt: What did you say the driver was called?16:06
ailoFound a nice tutorial on how to write device drivers for linux, as well as modules. Both are something I don't really what they are right now. http://www.freesoftwaremagazine.com/articles/drivers_linux http://www.linuxtopia.org/online_books/linux_kernel/linux_kernel_module_programming_2.6/index.html16:46
ailoI'd love to learn all that right away, but it's time to do other things for a while16:47
Len-nbailo, netbook driver is ath9k.17:00
Len-nbThe list of modules is much longer... aht9k, mac80211, ath9k_common, ath9k_hw, ath, cfg8021117:03
Len-nbprobably the ath9k_hw is probably the one that plays with the irq17:09
ailoLen-nb: Well, at least that driver is FOSS http://linuxwireless.org/en/users/Drivers/ath9k17:20
len-dtailo,  the question is if the problem is that or NM17:22
ailolen-dt: What is the model name for that notebook. I had a crazy idea. I might try to find a used one and buy it :P17:28
len-dtIt says KV6017:29
ailoAnd he brand?17:29
len-dtacer aspire one netbook17:29
len-dtthe acer aspire is a series of netbook/laptops.17:30
len-dtailo, I have found it is one of the more usable netbooks. My wife has the HP (don't buy one) which has had more HW problems and has no pgup or pgdn keys even with funct.17:33
len-dtAs a small computer the netbook is wonderful, it is light and small and yet complete.17:34
ailoI've actually had good experience with HP's17:35
len-dtI think the HP laptops are probably better, it is the netbook I don't like.17:35
ailoAnd ACER I often find is cheap for the performance you get, but it gets hot and noisy instead17:35
len-dtCut too many corners...17:35
len-dtI have not found it too hot... though it does get warm. The atom chip is cooler than others.17:37
ailolen-dt: The IEEE that I've been using gets pretty hot with the atom, though it's kind of old. More recent notebooks are pretty splendid for the cost17:40
len-dtailo, I will say that the HP battery seems to be lasting longer. My 3.5 hour battery is down to about 1.5 or so hours.17:40
ailoThe HP's I've seen around seem to last forever17:40
ailoA more recent HP was a lot worse quality wise. Really bad keyboard17:41
ailoBut there are thousands of models. Some are bound to be bad17:41
len-dtailo, The HP has a less nice wlan chip, it drops connection more often than the acer. Not a big thing though, might be antenna placement.17:42
ailoI think I need to change strategy. Perhaps assemble a list of computers that are know to cause problems, and then try to find one for sale. 17:42
ailoI should put an ad: Looking for really badly behaving hardware. Will pay a reasonable amount for it!17:43
len-dtI just added a note to the ubuntu aspire page about the internal mic. The left and right have to be unloacked and one full one and the other full off.17:44
len-dtThe HW sends left and right inverted and alsa mixes them...17:44
ailolen-dt: You should probably mention this at alsa-devel list, and maybe a pulse list as well17:44
ailoOr maybe a bug-report?17:45
ailoTo alsa, I mean17:45
len-dtThe pulse/alsa devs are aware. "there will be no fix"17:45
ailook17:45
len-dtThe problem is that it can't be auto detected.17:45
ailoIt's not the same at each boot?17:46
len-dtThe same chip is used different in different models.17:46
len-dtSo if they fix my problem they break someone elses box17:46
ailoAnd they don't do model specific fixes17:47
ailoWhy did you think the HP was worse again? M)17:47
ailo;)*17:48
len-dtI don't know if they can. 17:48
len-dtkeyboard is lacking keys I use all the time. wireless seems less sesitive. HD light is hard to see. no line in jack for audio.17:49
len-dtSeems to me I had problems with the card reader too at one point. I haven't tried it for a while though.17:50
len-dtthe card reader on the acer had problems at one kernel release too.17:50
len-dtIts funny because the OS sees it as a usb device and a usb stick or a USB card reader works fine...17:51
len-dteven with the same SD card.17:51
len-dtHP has had problems with the sound. But not with 12.04, when we first got it I had to manually switch the output from headphone to speaker... some config change or something. It seems to be fixed though. I put 12.04 in and it just works.17:53
ailoI'm getting more and more convinced about the HP. At least for audio use :P. I would guess you can run jackd at a lower latency and without xruns caused by the network manager17:55
len-dtBut no audio in.17:56
len-dtSo what would the point be?17:56
Len-nbailo, when I get the usb audio IF, I will try it on both.17:59
ailoLen-nb: I,ve rarely used builtin devices for recording, so that would be no problem for me. But, when usb is the only option otherwise, I guess that is a problem in itself. At least from how it seems18:02
ailoI think this must be the single biggest problem in the linux pro audio world right now in fact18:02
ailoIn a modern world you'd like to be able to move away from pci cards18:03
ailoFirewire is great, if you have a port for it. For now, that is the only type of notebook I could imagine getting for audio use18:04
ailoAlso since I already have a functioning firewire device18:04
ailoWe use my friends macbook at times with it, since we only use puredata18:05
ailoI'd love to install linux on it, but it's not my hardware, so :D18:05
Len-nbailo, the big plus with the netbook is size. If there was a proper USB2.0 audio standard then I think the max number of inputs likely to be used would be available.18:07
Len-nbReally, once I start carrying more than two mics, the size of a notebook computer doesn't matter and the advantage of using a netbook is gone.18:08
Len-nbailo, having said that... the one port (fast even) that every computer has these days is Ethernet. It would be nice to see cheap ethernet sound IFs.18:10
Len-nbWith an open standard. It should be possible to add an ethernet plug to any of the FW/USB sound IFs now available.18:12
Len-nbJust put jack-net on there....18:13
Len-nbailo, how about a little box with two eth connectors and one FW connector.18:17
Len-nbailo, just put a message on the list with some thoughts about latency and workflows.19:13
ailoI still don't believe in shutting down stuff that should work19:16
ailoSomething like the NM should not be causing problems for audio19:16
ailoNothing should19:16
ailoI can understand not including processes that are useless on a audio desktop19:17
Len-nbI conclude that the few uses where really low latency matters are not uses where networking needs to be on.19:17
Len-nbwe have talked about a "record mode", but I think it makes more sense to think in terms of latency levels.19:17
ailoI don't agree with that19:17
ailoI think that is backwards thinking suitable for 200119:18
Len-nbwe have a new ISO in our daily.19:18
ailoA standard desktop is not causing any problems on most systems19:18
ailoI can put 100% load on both my cores, and that will not affect audio performance19:19
ailoOr not much19:19
Len-nbI agree with that because even my 8 year old desktop has no problems with it.19:19
ailoI'm more into not having to do any adjustments at all, and that someone can add stuff to their desktop without breaking audio performance19:20
ailoSince xruns aren't caused easily19:20
ailoAll I need to do is add two config options to the kernel and recompile + add realtime privilege19:21
ailoThat's it19:21
ailoAll desktops work just as well. Gnome3, XFCE, Unity19:21
Len-nbailo, for most uses, with latency set to reasonable levels. This netbook is fine.19:22
ailoNo software that I know of is causing xruns for me19:22
ailoInstead of making things complicated for the user, it might be better to solve some techincally complicated problems19:22
ailoSince then there would be no need to fix anything from the user side19:23
ailoAlso, I don't see why LTS 2012 should put too much weight on being compatible with machines from 100219:24
ailo2002*19:24
ailoIt's going to be the LTS for 4 years19:24
ailoAnd 4 years from now, computers from 2002 will be 14 years old19:25
ailoThat's pretty old19:25
Len-nbthe only use that would cause problems with this netbook are live uses. And really i am not sure that this is the appropriate hardware for that seeing as HW synths are more robust anyway. and so are guitar effects. maybe cheaper too.19:25
ailo5 years back makes more sense to me19:25
Len-nbailo I was not suggesting making 8 year old machines work, only pointing out I have one that does... without any trouble or extra configuration.19:26
ailoThe older netbooks are a bit like P3 computers, aside from having slightly better graphic cards19:26
ailoAt least the single core ones19:27
Len-nbThis Netbook is less than two years old19:27
Len-nbThe new ones are not any better. They are not made for audio, but for browsing. I would not suggest that an audio distro be based on one.19:28
ailoI didn't mean to say we shouldn't support netbooks. I think they are fine, and support reasonable graphic load as well. Their weak point may be processing power, which is not really that much affected by the desktop and its processes in my experience19:29
Len-nbIt is interesting to see how much can still be done. I just want to see how far I can push it.19:29
ailoSo, they will perform poorly nevertheless, except they can support a more modern UI19:29
Len-nbThe nice thing is that they can be used for audio at all. And they can do it reasonably well. One's expectations have to fit the HW.19:34
Len-nbailo, anyway, assuming a reasonably new machine.... what changes should we be making for 12.11 now that there are daily builds...19:35
Len-nbailo, I have been looking qasmixer for audio IF that do not need their own mixer.19:38
Len-nbThis is not to replace pavucontrol, but to be in the mixers menu19:39
Len-nbfor use when setting up levels to use with jack.19:39
ailoI'll have a look19:44
ailoLen-nb: Pretty neat19:47
ailoNice to have both pulse and alsa there19:48
ailoStrange things happen when I move the pulse level19:48
ailoBoth pcm and master are affected19:49
ailoI can see that some people would prefer that to the pulsemixer19:52
Len-nbailo, try setting pavucontrol beside and control PA with that while watching what happens to the alsa levels.19:52
Len-nbI was not thinking to replace the pulse controller, but the xfce mixer19:53
ailoI didn't mean that you should replace it19:54
ailoBut, I still think some people might use this one more often than pavulcontrol19:54
Len-nbIt is nice to everything on one page.19:55
Len-nbI could even use it for the envy24 for most things.19:55
ailoI do think it would be good to have a trouble-shooting helper20:06
ailoSort of like the "record mode" you have been talking about20:06
ailoI guess it would be convinient to be able to toggle many things with one button20:07
ailoBut, I wouldn't want to call it "record mode", since it's really more of a last resort20:07
ailoMore like a workaround for specific issues20:08
Len-nbailo, "record mode" was not my name for it. just what was being used.20:12
Len-nblow latency tweak might be better.20:12
ailoI don't think it would get you lower latency either20:13
ailoShutting off NM would only fix issues for normal latency on certain machines20:13
ailoIt won't lower it for anyone20:13
ailoAnd I don't expect there are any other tweaks that will do that either20:14
ailoI don't expect there will be anything that will enhance performance much at all20:14
ailoThat is why I object to the idea of having a "record mode" button, because it would be falsely suggesting that you do get a performance boost, when most likely it does nothing at all20:16
ailoOther than shut down things that you might now need to shut down20:19
ailoJust out of nowhere I'm having huge problems with xruns using my builtin card20:25
Len-nbailo,  on this machine minimum latency without NM is -p128 but with, it is 1024 with no xruns. 20:26
ailoLen-nb: Yes, and I'd say 128 is quite a high latency on a modern system, so we're not talking about improving latency. More so about fixing an uncommon problem which prevents you from having "normal" operation20:32
ailoThe goal should be at least 64 on a fairly modern machines, like dual core and onwards20:34
ailo128 to me is a bit too slow20:35
ailoDepending on the machine probably, but still20:35
ailoNetbooks are a bit like P3 when it comes to processing power, so 128 is probably a good lowest latency for them20:36
ailoThat's what I would get with a P3 and a realtime kernel, not too long ago20:37
len-dtailo, I will see what I get with the usb IF when I get it. The 128 may be a hardware thing to get away with a cheaper card.20:51
ailo2021:29
ailolen-dt: Interesting. The kernel that had "threadirq" put as a config option for the build was giving me xruns like crazy21:41
ailoWith the rtirq script using that kernel I got the opposite effect of what you would expect21:42
ailoI'm on the same exact kernel now with the only diff being that this boot option was not added during the build21:42
ailo"threadirqs"*21:43
ailoIt's the same with using it during boot-time. Just checking to be sure :P. I didn't notice this before21:50
len-dtailo, fun with tuning.21:58
len-dtamybe that option turns it off?21:59
len-dts/amybe/maybe/21:59
ailolen-dt: No, it turns it on for sure22:11
ailoI've found that this machine will start misbehaving with the rtirq script enabled22:11
ailoI double-checked with the -lowlatency on Ubuntu Studio, and it's the same thing22:12
ailoDon't have the energy to find out why today. But I'm coming to the conclusion that in normal cases the rtirq script is superfluos and should perhaps only be used to fix problems22:13
ailoHaving it on by default may cause just as many problems as it fixesa22:14
ailoOr the script just needs to be edited22:14
ailolen-dt: Did you ever try moving moving away the script and try without it?22:15
ailoAll though, it doesn't fully help because threadirqs are enabled anyway22:16
len-dtailo, no. I haven't. It doesn't seem to hurt this desktop anyway.... well I did move all the pci cards around.22:16
ailoWe need a kernel to test without that option enabled, but with PREEMPT config22:16
len-dtailo, the web pages to do with it do say that somethings are high with out the script.22:17
len-dtUSB is kinda wonky anyway. on some machines some of the internal peripherals use USB ports too22:19
ailolen-dt: Normally the rtirq script should do nothing at all, since normally you don't have a problem. I never heard of someone getting problems because of it though, and this is the first for me. That is why I would like to see if it is the same for you22:19
len-dtailo, How do I test then?22:19
len-dtHow do I turn it off?22:20
ailolen-dt: First we need a kernel without the threadirqs enabled, since -lowlatency has it hardcoded22:20
ailoIt's edited into the source code. I checked with abogani before22:20
ailoI could build one and pass a link later22:21
ailoMaybe tomorrow, or the next day22:21
len-dtOK, whenever.22:21
len-dtAs always I'm not always available...22:21
ailolen-dt: What arch btw?22:24
ailoNo matter. I should build both anyway22:24
len-dtailo, 32 bit... both machines22:26
len-dtailo, I just took out the yamaha rm602 mixer and put the mackie 1604 in... 22:28
len-dtthere is a big diff in sound even with an avi file.22:29
ailolen-dt: That Yamaha looks a bit old :)22:29
len-dtThe mackie is not much newer actually. It is one of the first 1604s with the 6 mic preamps22:30
ailoI have an older Heath & Allen, which can be controlled with a commodore 64. Used to cost a whole lot. Got it cheap some years ago. Killed it unfortunately :(22:31
ailoOr is it Allen and Heath?22:31
len-dtailo, the yamaha was made to use with an old cassette porta studio kind of setup.22:31
ailoBeen mostly using a Behringer, 16 ch mixer. Not bad really22:31
ailolen-dt: Ok, so it wasn't exactly top notch22:32
ailoWith our live setup with the band we're down to using only the firewire device22:32
len-dtIt was easy to access and hook up when we moved in. There wasn't room for the mackie. Now that I need the phantom power...22:33
ailoThat and a laptop, + our instruments22:33
len-dtYa mixers are not really needed for recording any more.22:33
len-dtless stuff to hook up and everything.22:34
ailoI have a couple of really decent preamps, and mics to go with them, so vocals, and anything acoustic stereo is going to sound really ok22:34
ailoFor the rest it's mostly sm58 and mics like that22:35
ailoA couple of audo line CM3's22:35
len-dtThats why I'm getting the ART pre. It is a lot easier to lug around than the mackie.22:36
ailoYou only need a lot of mics for drums, or when you record stuff live22:36
len-dtI started on drums, but I haven't had a kit for years now.... I have an 8pad box and hydrogen...22:38
len-dtI kind wish I at least had a snare... so many different sounds depending on how it is played.22:39
ailoI'm a drummer too, though I began plauying guitar at the same time. I also play piano. Have a trumpet, but haven't had the time to learn it. Strange instrument :P. Played some violin too22:44
ailoSo, mostly string instruments and percussion22:44

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