2014-05-09 00:03 rz2k has quit [] 2014-05-09 00:55 jluis has quit [Ping timeout: 245 seconds] 2014-05-09 01:08 jluis has joined #qi-hardware 2014-05-09 01:21 dos1 has quit [Ping timeout: 264 seconds] 2014-05-09 01:54 atommann has joined #qi-hardware 2014-05-09 01:59 jekhor has joined #qi-hardware 2014-05-09 02:05 hmm: http://hackaday.com/2014/05/08/testing-the-efficiency-of-pcb-etchants/ 2014-05-09 02:11 jekhor has quit [Quit: Leaving] 2014-05-09 02:42 atommann has quit [Quit: Leaving] 2014-05-09 03:03 xiangfu has joined #qi-hardware 2014-05-09 03:55 atommann has joined #qi-hardware 2014-05-09 03:58 atommann__ has joined #qi-hardware 2014-05-09 04:00 atommann has quit [Ping timeout: 265 seconds] 2014-05-09 04:56 wpwrak has quit [Ping timeout: 240 seconds] 2014-05-09 05:24 wolfspraul has joined #qi-hardware 2014-05-09 05:51 wpwrak has joined #qi-hardware 2014-05-09 06:09 wej_ has quit [Ping timeout: 260 seconds] 2014-05-09 06:42 wej has joined #qi-hardware 2014-05-09 06:56 wej has quit [Ping timeout: 252 seconds] 2014-05-09 06:57 wej has joined #qi-hardware 2014-05-09 07:13 xiangfu has quit [Ping timeout: 265 seconds] 2014-05-09 07:23 yeah, this exact notion of "proper OS" had been preventing me from using Linux on desktop for many years 2014-05-09 07:27 didn't prevent me, but it's just not good design. or should I say, lack of any design whatsoever? 2014-05-09 07:28 neither unix nor c were ever designed; they went from "kept together with wd-40 and duct tape" to "the committee decides where do we add more wd-40 and duct tape" 2014-05-09 07:29 and if you dare to tear off even the tiniest chunk of the duct tape, the whole contraption folds 2014-05-09 07:29 I'm not even exaggerating 2014-05-09 07:32 so you just went blaming from unix to c, good move :) 2014-05-09 07:32 well, they're tightly related. and suggesting unix as an example of proper... anything is absurd 2014-05-09 07:33 practically everything else that exists is just even more horrible, though 2014-05-09 07:33 that's what i was going to say.. there is no "proper" 2014-05-09 07:34 there is "proper", deep within research labs and the like 2014-05-09 07:34 sadly, software, especially free software, is governed by network effects, not quality 2014-05-09 07:34 sometimes the research labs are even more far away from proper, untied to real life and real application 2014-05-09 07:35 some of them are, some of them are far more practical than anything the industry offers 2014-05-09 07:35 how about, I dunno, a JavaCard with a sandbox that is mathematically proven to be impenetrable? 2014-05-09 07:36 something something openssl chrome firefox javascript 2014-05-09 07:36 50 years after, somebody proves that your mathematics is wrong 2014-05-09 07:36 not going to happen. 2014-05-09 07:36 and laughs at "shitty design" 2014-05-09 07:36 you still have to care about a bunch of other kinds of attacks, say, side-channel attacks allowing to extract key material 2014-05-09 07:37 well, designers of unix definitely had no idea you wanted you flash drive mount automatically 2014-05-09 07:37 but at least a random guy from the street can't execute and persist any code he likes on your "secure" container 2014-05-09 07:38 new technologies arise, making older designs obsolete. You can't account for everything 2014-05-09 07:38 design of unix was outdated right when it has appeared, and not too far long in the future everyone just started adding silly extensions 2014-05-09 07:39 i'm not sure about that.. 2014-05-09 07:39 xiangfu has joined #qi-hardware 2014-05-09 07:39 about what, unix wars or that it was broken from the start? 2014-05-09 07:39 that unix was outdated right when it appeared 2014-05-09 07:40 take a look at ALGOL-68 and Burroughs B5000, for example 2014-05-09 07:40 and that wasn't exactly rocket science at the point 2014-05-09 07:40 pcercuei has joined #qi-hardware 2014-05-09 07:41 if you think unix is somehow innovative in timesharing, virtual memory, etc, etc, just take a look at the design of THE multiprogramming system 2014-05-09 07:41 there is no "good" and "evil", i'm pretty sure what you mentioned had its drawbacks. There is a reason unix survived 2014-05-09 07:42 that reason is not technical. it's called "network effects" 2014-05-09 07:42 i doubt that 2014-05-09 07:42 well, it's easy to eliminate technical reasons. you just have to look at the design of contemporary systems 2014-05-09 07:43 so when you eliminate the impossible, the rest, however doubtful, must be the truth 2014-05-09 07:44 i prefer to believe in natural selection.. the better survices, the worse dies 2014-05-09 07:44 if unix survived, and nobody knows about Burroughs B5000, than unix is better - easy. 2014-05-09 07:45 more fit ≠ technically better. exactly what I'm telling you about. 2014-05-09 07:46 well, this just proves that fitness is not all about technical greatness 2014-05-09 07:46 and there's nothing good about that 2014-05-09 07:47 fitness considers immediate, short-term gain, usually sacrificing long-term one 2014-05-09 07:47 don't even talk about long term in this area... 2014-05-09 07:47 do I have to point you to the amount of idiotic vulnerabilities in software written in C? 2014-05-09 07:48 do I have to remind you that today, practically any system is vulnerable if poked just a little bit harder than usual? 2014-05-09 07:48 do I have to explain that this does not have to be the case? 2014-05-09 07:48 do i have to point out that C language is all about trade off? 2014-05-09 07:49 the tools is more dangerous, but allows to do more 2014-05-09 07:49 and sometimes more efficiently 2014-05-09 07:49 sb0 has joined #qi-hardware 2014-05-09 07:49 if you don't like it, choose another tool 2014-05-09 07:49 I can't, that's the whole problem 2014-05-09 07:50 all the OSes are written in C. my bank uses C. my hospital uses C. the thing in my pocket that has all the information about me uses C. so on. 2014-05-09 07:50 then the time for the "new" tool can not come yet 2014-05-09 07:51 so you're saying, ummmm, "C is good because network effects prevent adoption of anything else". 2014-05-09 07:51 that's amazing logic, I can use it to justify anything 2014-05-09 07:51 when people reached the limits of wooden tools, then invented how to used stone tools 2014-05-09 07:51 so it seems like C yet has something to say 2014-05-09 07:53 and talking about the tradeoffs... it's basically a UI failure. C makes it very easy to write dangerously incorrect code 2014-05-09 07:54 it could make that hard, but didn't. thus, bad design. 2014-05-09 07:54 when your cars trap people inside on collisions and catch fire, you don't say "that's a design choice", whether it was one. you recall the damn cars and make sure this never happens again 2014-05-09 07:55 but I guess the field will be so immature until most of the people who think suck tooling is OK die. 2014-05-09 07:55 that's why none of automotive companies writes C code by hand anymore :) 2014-05-09 07:56 of course they do, MISRA-C is explicitly targeted at handwritten C code 2014-05-09 07:56 have you heard of MISRA-AC-AGC? 2014-05-09 07:56 how widely is it deployed? 2014-05-09 07:56 don't get me started about automatic code generation, i've been in the automotive industry for years 2014-05-09 07:56 viric_ has joined #qi-hardware 2014-05-09 07:57 and anyway, automotive even has it relatively good. consumer is where the horror truly lies 2014-05-09 07:57 I grant you that automotive, or aerospace, are able to deal with the fallout (but at what cost?) 2014-05-09 07:57 ..and ACG is used very widely 2014-05-09 07:57 now look at openssl 2014-05-09 07:58 yeah, thats another story 2014-05-09 07:58 or linux--local privilege escalation is so often, people don't even talk about it a lot 2014-05-09 07:58 they should learn the lesson: "everyone needs formal verification" 2014-05-09 07:58 kyak++ 2014-05-09 07:58 have you seen Coq? 2014-05-09 07:58 its funny. A lot of companies now want to use Linux in the automotive segement, but the Linux kernel coding sytle clashes with the MIRSA coding style. 2014-05-09 07:58 or CompCert? 2014-05-09 07:58 nope, i've seen Polyspace 2014-05-09 07:59 absolutely do take a look at CompCert. it's a formally verified C compiler that optimizes code at about GCC's -O1 2014-05-09 07:59 meaning there can be no miscompilation. 2014-05-09 07:59 viric has quit [Ping timeout: 245 seconds] 2014-05-09 07:59 viric_ is now known as viric 2014-05-09 07:59 there's the issue of verifying the code itself, but it's another one :) 2014-05-09 08:00 intersting.. then you have a look at Polyspace, it's a formal verification tool (using abstract interpretation) that works on C/C++/Ada code 2014-05-09 08:00 I will. have you also seen KLEE? 2014-05-09 08:00 i wonder how CompCert goes about DO-178 qualification... 2014-05-09 08:00 nope 2014-05-09 08:00 that's LLVM's abstract interpreter 2014-05-09 08:01 DO-178 is one of the goals for CompCert development, yes. no idea if they actually got the papers 2014-05-09 08:01 it's a big pain in the industry, actually.. the lack of qualified compiler 2014-05-09 08:01 ha 2014-05-09 08:01 and the companies do weird things to prove their object code is correct to source code... 2014-05-09 08:02 seems you need to cooperate with your friends from academia a bit more ;) 2014-05-09 08:03 well.. there will always be a gap between research and development 2014-05-09 08:04 whitequark: please point me to KLEE, google shows irrelevant results 2014-05-09 08:04 http://klee.github.io/klee/ 2014-05-09 08:05 KLEE is a bit... dated 2014-05-09 08:05 but in right hands, it could still be very much useful (if sometimes not directly) 2014-05-09 08:06 kyak: there's also Coq, which is the tool you use to efficiently build verified software 2014-05-09 08:06 i'll have a look 2014-05-09 08:06 I'm currently working through a book, Software Foundations, explaining how to use it 2014-05-09 08:06 http://www.cis.upenn.edu/~bcpierce/sf/ 2014-05-09 08:06 but it's a huge pain in the ass to deal with, unfortunately 2014-05-09 08:08 like, I've spent six hours yesterday trying that my Peano-representation-to-binary-digits converter is correct, which is probably one of the most basic things you could imagine 2014-05-09 08:08 I failed 2014-05-09 08:08 trying to prove* 2014-05-09 08:08 whitequark: btw, there are tools that let you automatically generate tests for 100% model coverage (the model, from which the code is generated). It uses formal methods, so 100% coverage is guaranteed (unless there is "dead code", which you then automagically find) 2014-05-09 08:08 what about dynamical invariants? 2014-05-09 08:08 what's that? 2014-05-09 08:08 like, polymorphism? 2014-05-09 08:09 hrm, no. something like "if(fuel_low && fuel_high) {", that can't ever be dynamically true, but there's no way to statically infer that 2014-05-09 08:09 how would your tool handle it? 2014-05-09 08:09 I'm not talking about the case when there's two sensors for fuel_low and fuel_high; that's just the differently interpreted output from a single sensor. 2014-05-09 08:10 ah, it would prove it unsatisfiable 2014-05-09 08:10 as expected; and what'd you do? 2014-05-09 08:10 the toos would show it to you, it is you, the developer, who needs to justify 2014-05-09 08:11 the tools knows nothing about the physics behind the system, just the mathematics.. 2014-05-09 08:11 well, nevermind, actually. the regulations usually dictate a highly restricted style of programming anyway 2014-05-09 08:12 what I mean is that such tools are OK for some limited areas, but for other places rapidly become inapplicable 2014-05-09 08:12 you can verify an L4 microkernel, say (it has been done), but there probably will not be a verified kernel for desktops for decades 2014-05-09 08:12 it's just too complex 2014-05-09 08:13 these tools are good for algorithms, that is, the application software. It is indeed very hard to apply to system software 2014-05-09 08:13 or basic software, if you wish 2014-05-09 08:13 there are still ways to gain confidence in the behavior of the overall system, namely split the system into smallest components with least authority and prove that the part that communicates messages is correct 2014-05-09 08:13 (the microkernel approach, if you'd like) 2014-05-09 08:14 e.g. this has been done to get a "verified" browser, where Webkit is ran in an OS sandbox, and only the controlling part is verified 2014-05-09 08:14 but they require a radical change in the software architecture, which is even less likely to happen than switch from C or something 2014-05-09 08:15 and probably radical changes in minds.. 2014-05-09 08:15 well, that's exactly the problem :) 2014-05-09 08:16 convince people that formal verification is good. then, convince them it's possible. then, convince they should invest in it. 2014-05-09 08:16 whitequark: anyway, here's the formal model verifier: http://www.mathworks.com/products/sldesignverifier/ and the code prover: http://www.mathworks.com/products/polyspace-code-prover/ 2014-05-09 08:16 any one of the three steps is nearly impossible to achieve 2014-05-09 08:16 have fun watching webinars, if you have some time :) 2014-05-09 08:16 ugh. my brain doesn't accept audio information 2014-05-09 08:17 anyway, I have an overall understanding of formal methods 2014-05-09 08:17 if you want to get your hands dirty, just let me know - i can issue you a temporary license 2014-05-09 08:17 oh, now this is getting interesting 2014-05-09 08:18 (although I still prefer FOSS for the reason that I can share the results and knowledge...) 2014-05-09 08:18 you are now a licensed code verifier 2014-05-09 08:18 :D 2014-05-09 08:18 kyak: oh also, do take a look at clang-analyzer too 2014-05-09 08:18 it's a best-effort thing, but it catches a lot of bugs in practical software, like Linux 2014-05-09 08:18 allright, have to go now. whitequark, i will :) saved a couple of bookmarks 2014-05-09 08:25 This morning I was wondering how hard it is to build a verification tool that automatically finds race conditions in a single driver module 2014-05-09 08:25 e.g. typically a driver has only a single entry and exit point 2014-05-09 08:26 but in the entry and exit functions you typically have some foobar_register(foobar_ops); foobar_unregister(foobar_ops) 2014-05-09 08:26 where foobar_ops is a collection of function pointers 2014-05-09 08:26 larsc: have you seen tsan? 2014-05-09 08:26 from the point on where foobar_register has been called you have to assume that those functions can be called concurrently 2014-05-09 08:27 whitequark: no 2014-05-09 08:27 oh. 2014-05-09 08:27 it's just what you want 2014-05-09 08:27 https://code.google.com/p/data-race-test/wiki/ThreadSanitizer 2014-05-09 08:27 a right, threadsanitizer 2014-05-09 08:27 hmmm, could you try something like 2014-05-09 08:27 running it over usermodelinux? 2014-05-09 08:28 I don't want to do live analysis 2014-05-09 08:28 oh, a static analyzer 2014-05-09 08:28 I've never heard of static data race analysis, to be honest 2014-05-09 08:31 I was thinking about first splitting the code into blocks of sideeffect free code, then build a graph of which block may follow after which other block. But I'm afraid there will be a state explosion 2014-05-09 08:31 indeed 2014-05-09 08:32 you can probably split them into ranges or sets somehow 2014-05-09 08:32 I'm sure there's been literature on the topic, have you looked? 2014-05-09 08:33 no, just had the thoughts a couple of hours ago 2014-05-09 08:35 http://www.mathworks.com/help/bugfinder/ref/raceconditions.html 2014-05-09 08:36 and now i'm really out 2014-05-09 08:38 hm, what can run concurrent with what else typically only changes when you add/remove a new concurrent function to the system, or if you take/release a lock 2014-05-09 08:39 I can't parse that sentence 2014-05-09 08:40 when you have two functions f1 and f2 and the can run concurrently that means that any instruction in f1 can be followed by any instruction in f2 and vice versa 2014-05-09 08:41 umm, that's a very simplified view 2014-05-09 08:42 I think you must consider a memory model 2014-05-09 08:42 larsc: really though, you don't need to consider all instructions 2014-05-09 08:43 you only need to ensure that concurrent access is either atomic or protected by a lock 2014-05-09 08:43 yes, thats why I said split things into blocks of side-effect freeness 2014-05-09 08:43 no, I mean, you don't have to analyze all possible parallel paths at all 2014-05-09 08:43 concurrent paths, rather 2014-05-09 08:44 you only have to analyze a single path, because the predicate "protected by a lock" only considers a single thread 2014-05-09 08:44 ("atomic" is trivial) 2014-05-09 08:44 typically there is no global lock 2014-05-09 08:45 so you will have to categorize data into two categories: 1) owned by a thread T 2) protected by lock L 2014-05-09 08:45 then, for category 2, you'll have to prove that no accesses outside a section protected by a lock happen. this is a relatively simple flow analysis 2014-05-09 08:45 for 1, it's much trickier 2014-05-09 08:46 but I hope that kernel has some sane standard notion of ownership 2014-05-09 08:47 and there should never be any data that is neither owned by a specific thread nor protected by a lock 2014-05-09 08:48 makes sense? 2014-05-09 08:48 yes 2014-05-09 08:49 but I think it might be more complex 2014-05-09 08:49 I will happily discuss it; I'm fairly interested in the topic 2014-05-09 08:49 tbh I think you may be onto something; I can't recall any existing tools that work like that 2014-05-09 08:50 * larsc too, but I'm trying to get work done right now ;) 2014-05-09 08:51 What I meant was that there are other ways of mutal exclusion then just taking a lock 2014-05-09 08:51 e.g. before you register your callback ops you know that data accessed before that point can not be concurrently accessed in the callbacks 2014-05-09 08:52 that's ownership 2014-05-09 08:52 i.e. you can skip locking if you own the thing. but you're right in that now that becomes modal 2014-05-09 09:05 I think I would describe it with code paths being dead or alive 2014-05-09 09:05 there are certain events that mark a code path dead or alive 2014-05-09 09:05 e.g. a taking a mutex makes all other codepaths that use the same mutex dead 2014-05-09 09:06 you get in problems though when the calculation whether the code is dead or alive becomes turing complete 2014-05-09 09:06 yes, that's why I suggested ownership 2014-05-09 09:06 e.g. if (rand() % 2) mutex_lock() 2014-05-09 09:07 ownership usually corresponds to some well-defined domain concept 2014-05-09 09:07 which people won't mess with just for the sake of maintainability 2014-05-09 09:08 say, memory allocated on stack is only owned by the caller 2014-05-09 09:08 memory allocated with malloc is owned by caller unless put into memory that belongs to someone els 2014-05-09 09:13 and you rarely if at all transfer ownership entirely 2014-05-09 09:13 perhaps only for something like buffers in a network stack 2014-05-09 09:17 can you transfer ownership to None? 2014-05-09 09:17 e.g. every thread needs to take a lock? 2014-05-09 09:18 sure, though I would call that "Shared" 2014-05-09 09:19 ok 2014-05-09 09:21 it's basically a standard poisoning scheme 2014-05-09 10:22 larsc: frama-c.com? 2014-05-09 10:22 I'm being told it does what you want 2014-05-09 10:27 atommann__ has quit [Ping timeout: 264 seconds] 2014-05-09 10:29 porchao has quit [Ping timeout: 264 seconds] 2014-05-09 10:37 porchao has joined #qi-hardware 2014-05-09 10:38 atommann__ has joined #qi-hardware 2014-05-09 10:38 I'll take a look, thanks 2014-05-09 10:51 many years ago, there was a tool called 'spin' or so 2014-05-09 10:52 decades, even 2014-05-09 10:52 * wpwrak celebrates the return of the intertubes 2014-05-09 10:53 it was... http://spinroot.com/spin/whatispin.html 2014-05-09 10:54 it's still used, it seems :) 2014-05-09 10:55 fascinating 2014-05-09 10:56 (spin) "still used" and why not ? it's a great tool 2014-05-09 10:59 atommann__ has quit [Quit: Leaving] 2014-05-09 10:59 last time I touched it, it was in early 0s 2014-05-09 11:00 and back then I thought I was using an old tool 2014-05-09 11:00 well, unless you design protocols for a living it's not a tool you should need every day ... ;-) 2014-05-09 11:00 I coulnd't find any other tool that did that, though 2014-05-09 11:00 valhalla_ is now known as valhalla 2014-05-09 11:00 open source tool I mean 2014-05-09 11:01 whitequark: (etchant comparison) not terribly useful, given that they only tried two 2014-05-09 11:02 mmm yes, it's only mildly interesting 2014-05-09 11:02 I definitely should try FeCl3-with-a-sponge 2014-05-09 11:02 seems to produce fascinating results. I'm not sure why *exactly* is it faster 2014-05-09 11:03 FeCl is just a mess. have you ever tried it ? all the lovely stains ... 2014-05-09 11:03 I totally did 2014-05-09 11:03 had a 1L bottle of FeCl3 and used it for ~6 months 2014-05-09 11:04 and you still want to go back to *that* ? :) 2014-05-09 11:04 it didn't really bother me in the ways you describe 2014-05-09 11:05 it was somewhat slow and uneven, but some of that can be attributed to poor tradecraft back then 2014-05-09 11:05 I don't ever want to deal with hot FeCl3 though 2014-05-09 11:06 xiangfu has quit [Remote host closed the connection] 2014-05-09 11:06 oh, it "works". but you need to warm it, any spills cause stains (and the messy procedure means that spills are more likely), it very quickly loses transparency, and it's a pain to get rid of the spent acid. 2014-05-09 11:07 just pour it down the drain 2014-05-09 11:08 compare to HCl+H2O2: works fine at room temperature, very low spill risk and spills are colorless (i assume - haven't actually had one i noticed yet), stays clear all the way, you just let it dry and then dispose of the salt. 2014-05-09 11:08 (transparency) is it ever transparent? 2014-05-09 11:08 in russia, there are no fish :) 2014-05-09 11:09 and acquiring H2O2 is still a pain... 2014-05-09 11:09 eh. as if a whopping 10g of copper would affect *anything* 2014-05-09 11:09 fecl ? well, sufficient to see the pcb. but when etching starts, it all gets black 2014-05-09 11:09 and 10g of copper is how many pcbs? a hundred? 2014-05-09 11:11 how big are your pcb ? and what sort of copper coating do you have ? 1/2 oz, 1 oz, 2 oz ? single-or double-sided ? 2014-05-09 11:11 say 1/2oz double-sided, 10x10cm would be most common 2014-05-09 11:12 and I usually pour the copper in planes on the board 2014-05-09 11:13 so let's say 70% coverage 2014-05-09 11:14 fine 2014-05-09 11:14 that should be about 1 gram of dissolved copper per board 2014-05-09 11:22 seem that about 10 ug are enough to reach LD50 in trouts and minnows. so that gram is about 50 fish. http://www.southwestsalmon.org/wp-content/uploads/2014/01/Morris_Stratus_CuTox_RBT_FHM_LowHardnessH2O.pdf 2014-05-09 11:23 umm, µg? not µg/L? 2014-05-09 11:24 ah, sorry, yes. tought that had used the accumulated value 2014-05-09 11:24 yepp, µg/L. now consider in how much water exactly that 1 gram of copper is dissolved. 2014-05-09 11:24 while I appreciate the sentiment and everything, the fact is, it's not going to do anything 2014-05-09 11:25 neither will 10g neither 100g (over the course of a year or so, which seems reasonable) 2014-05-09 11:58 jluis has quit [Remote host closed the connection] 2014-05-09 12:58 FDCX has quit [Remote host closed the connection] 2014-05-09 13:06 atommann has joined #qi-hardware 2014-05-09 14:25 dos1 has joined #qi-hardware 2014-05-09 14:35 nice feature ;) "cp: will not overwrite just-created ... with ..." 2014-05-09 14:36 Is the best PCB etchant in every kitchen ? -- http://www.instructables.com/id/Is-the-best-PCB-etchant-in-every-kitchen-/?ALLSTEPS 2014-05-09 14:36 it's not in mine - i keep the hcl outdoors :) 2014-05-09 14:42 nicksydney_ has quit [Remote host closed the connection] 2014-05-09 14:43 nicksydney has joined #qi-hardware 2014-05-09 14:45 wpwrak: nice idea about casing http://www.instructables.com/id/ChronosMEGA-a-wrist-watch/?ALLSTEPS 2014-05-09 14:46 it has got it's own design page http://www.shapeways.com/model/1809825/chronosmega-watch-case.html?modelId=1809825&materialId=81 2014-05-09 14:50 "Atmel ATmega328P QFP processor" *groan* 2014-05-09 14:52 wpwrak: change that to M0 smaller package and make more interesting display and call it WrakWatch :) 2014-05-09 14:53 you mean with a nice big wrecking ball chained to it ? :) 2014-05-09 14:55 not sure which ball you are referring to :) 2014-05-09 14:56 thought of hacking something like this for my son's school bag http://www.instructables.com/id/Wearable-Message-Board/?ALLSTEPS so it scroll his name across :) 2014-05-09 14:58 better make a tornado :) http://projects.qi-hardware.com/index.php/p/antorcha/source/tree/master/tornado 2014-05-09 14:59 uhhhh nice 2014-05-09 15:00 wpwrak: you can make few boards and sell it on tindie ... surely people will buy it 2014-05-09 15:02 wish we had less of a "you should do/make/..." culture here and more "i'll do/make/..." 2014-05-09 15:03 idea, proof of concept design, etc., all there. neatly pre-chewed for someone else to continue with. but no. guess the couch is just too comfty :) 2014-05-09 15:04 "i'm making RA8875 board" :) 2014-05-09 15:05 and soon "I'm making scrollable LED for backpack" 2014-05-09 15:05 wow the antocha design is nice 2014-05-09 15:06 do you have pic of the proto for antorcha ? 2014-05-09 15:10 liek this ? http://www.almesberger.net/misc/ant/proto2.jpg or in use: http://www.almesberger.net/misc/ant/edd1.jpg 2014-05-09 15:11 and this is tornado: http://downloads.qi-hardware.com/people/werner/tornado/proto1122.ogv 2014-05-09 15:12 viric has quit [Read error: Connection reset by peer] 2014-05-09 15:12 wow...cool 2014-05-09 15:12 (just on the bench - it's a bit tricky to take pictures of it running) 2014-05-09 15:13 would redesign it with a kl2x now, though. free usb :) 2014-05-09 15:13 will be interesting if later on i try that design and put the led into pyralux material like being used in here http://www.instructables.com/id/Making-flexible-PCBs-with-a-laser-jet-printer-or-c/?ALLSTEPS 2014-05-09 15:14 yeah using Pyralux will be interesting 2014-05-09 15:14 http://www.smokingresistor.com/2012/02/04/pyralux-flexible-circuit/ 2014-05-09 15:17 it's aim for rigidity. mechanical stress on that thing is already through the roof, so anything that helps to keep chips from popping off the circuit is hotly welcome 2014-05-09 15:20 viric has joined #qi-hardware 2014-05-09 15:33 rz2k has joined #qi-hardware 2014-05-09 15:35 nice ... a CR2032 holder you can "sink" into the PCB. http://www.memoryprotectiondevices.com/datasheets/BU2032SM-JJ-MINI-GTR-datasheet.pdf 2014-05-09 15:53 * ysionneau just received his components from seeedstudio 2014-05-09 15:55 just in time for the weekend :) 2014-05-09 15:55 yeah 2014-05-09 16:10 pcercuei has quit [Ping timeout: 240 seconds] 2014-05-09 16:10 time to plant things 2014-05-09 16:29 wej_ has joined #qi-hardware 2014-05-09 16:32 wej has quit [Ping timeout: 245 seconds] 2014-05-09 16:39 atommann has quit [Quit: Leaving] 2014-05-09 16:42 atommann has joined #qi-hardware 2014-05-09 16:57 atommann has quit [Quit: Leaving] 2014-05-09 17:25 hmm, seems that i may be able to shrink the kl26 from 48 to 32 pins. that would be neat :) 2014-05-09 17:38 pcercuei has joined #qi-hardware 2014-05-09 18:27 Hi larsc, are you still there ? 2014-05-09 18:28 nice PCB making technique http://goo.gl/aNzLHt 2014-05-09 18:28 less chemistry ;) 2014-05-09 18:49 apelete: yes 2014-05-09 18:51 glad to see you around :) 2014-05-09 18:53 larsc: stepping through jz4740_dma_start_transfer() with gdb (since the dma_complete callback is not being called in mmc driver) 2014-05-09 18:53 there's something I don't understand 2014-05-09 18:56 larsc: when it gets to line 338 (http://lxr.free-electrons.com/source/drivers/dma/dma-jz4740.c?v=3.12#L338) the value of src_addr is actually 56: 2014-05-09 18:56 http://paste.debian.net/98518/ 2014-05-09 18:57 did you set fifo_addr in the config? 2014-05-09 18:58 this need to point to the physical address of the mmc controlers data fifo register 2014-05-09 18:59 I set src_addr in case of DMA_DEV_TO_MEM transfer: http://git.seketeli.net/cgit/~apelete/qi-kernel.git/tree/drivers/mmc/host/jz4740_mmc.c?h=jz4740-dma#n182 2014-05-09 19:00 larsc: don't know if it is the same as fifo_addr 2014-05-09 19:00 no 2014-05-09 19:00 or wait 2014-05-09 19:00 I think it is 2014-05-09 19:01 56 is 0x38 which is JZ_REG_MMC_RXFIFO 2014-05-09 19:02 so that means host->mem_res->start must be 0 2014-05-09 19:02 which is wrong 2014-05-09 19:03 this line is fishy http://git.seketeli.net/cgit/~apelete/qi-kernel.git/tree/drivers/mmc/host/jz4740_mmc.c?h=jz4740-dma#n1032 2014-05-09 19:03 so I have a problem at "host->mem_res = devm_ioremap_resource(&pdev->dev, res);" 2014-05-09 19:03 http://git.seketeli.net/cgit/~apelete/qi-kernel.git/tree/drivers/mmc/host/jz4740_mmc.c?h=jz4740-dma#n1032 2014-05-09 19:03 host->mem_res should = res 2014-05-09 19:04 then host->base = devm_ioremap_resource(&pdev->dev, host->mem_res) 2014-05-09 19:05 the compiler should have actually screamed at your for that line 2014-05-09 19:07 larsc: he didn't, kept the scream for himself :-/ 2014-05-09 19:07 I'll fix the lines you're talking about and try again 2014-05-09 19:36 pcercuei is now known as zdrnk 2014-05-09 19:42 larsc: gdb won't let me print the content of host->mem_res in mmc_probe callback: http://paste.debian.net/98532/ 2014-05-09 19:42 larsc: src_addr looks ok, but dma still fails (and dma_complete still isn't called) -> http://paste.debian.net/98533/ 2014-05-09 19:43 (gdb) p src_addr 2014-05-09 19:43 $4 = 268570680 2014-05-09 19:43 (gdb) p dst_addr 2014-05-09 19:43 $5 = 14617216 2014-05-09 19:46 we'll get there 2014-05-09 19:47 dst_addr looks a bit short 2014-05-09 19:49 you don't seem to set JZ_MMC_CMDAT_DMA_EN 2014-05-09 19:49 hmm, not sure what you're talking about, let me look at the code 2014-05-09 19:50 you need to set the JZ_MMC_CMDAT_DMA_EN in the CMDAT register, otherwise the MMC controller will not tell the DMA controller that there is any data to transfer 2014-05-09 19:50 no data to transfer -> no callback 2014-05-09 19:52 okay I see, so I should set JZ_MMC_CMDAT_DMA_EN in jz4740_mmc_send_command() 2014-05-09 19:52 yes 2014-05-09 19:58 larsc: looks good to you http://paste.debian.net/98536/ ? (compiling) 2014-05-09 19:58 yes 2014-05-09 20:06 larsc: making some progress, kernel is now crashing: http://paste.debian.net/98538/ 2014-05-09 20:09 can you check which is the NULL pointer? 2014-05-09 20:09 larsc: how can chan->desc->vdesc be valid when chan->desc = NULL; ? 2014-05-09 20:10 it is not 2014-05-09 20:10 http://paste.debian.net/98541/ 2014-05-09 20:10 vdesc is desc + 20 or something 2014-05-09 20:10 so it will not be NULL 2014-05-09 20:10 but NULL + 20 2014-05-09 20:12 try to replace the else with else if (chan->desc) 2014-05-09 20:12 no 2014-05-09 20:12 that makes no sense 2014-05-09 20:13 this is stupid: 2014-05-09 20:13 chan->desc = NULL; 2014-05-09 20:13 vchan_cookie_complete(&chan->desc->vdesc); 2014-05-09 20:14 should be something like: vdesc = &chan->desc->vdesc; chan->desc = NULL; vchan_cookie_complete(vchan); 2014-05-09 20:14 chan->desc = NULL; looks strange to me, but I may be mistaken here 2014-05-09 20:14 larsc: ok, looks more logical 2014-05-09 20:14 let's try that 2014-05-09 20:15 I think it would even be fine to just swap the two lines 2014-05-09 20:16 this all happens while holding a lock, so there is no chance of a race condition 2014-05-09 20:17 ok 2014-05-09 20:21 also be aware that you need this commit http://git.seketeli.net/cgit/~apelete/qi-kernel.git/commit/?h=jz-3.13 2014-05-09 20:22 larsc: should I still invert the two following lines after list_del(&chan->desc->vdesc.node); ? 2014-05-09 20:24 yes 2014-05-09 20:25 ok 2014-05-09 20:42 larsc: now it fails in dma_complete() callback http://paste.debian.net/98551/ :) 2014-05-09 20:43 that's your function 2014-05-09 20:44 just drop the cache_inv for now 2014-05-09 20:44 ok 2014-05-09 21:09 wej_ has quit [Ping timeout: 260 seconds] 2014-05-09 21:14 kanzure has quit [Ping timeout: 265 seconds] 2014-05-09 21:16 just fixed a mistake where I forgot to init struct completion used by dma_complete callback 2014-05-09 21:17 larsc: more porgress, now failing with an I/O error in sd driver I guess -> http://paste.debian.net/98562/ 2014-05-09 21:21 but it detects the card correctly 2014-05-09 21:21 which means it is able to read data 2014-05-09 21:22 yes, the I/O error is from: 2014-05-09 21:22 ./block/blk-core.c:2330: printk_ratelimited(KERN_ERR "end_request: %s error, dev %s, sector %llu\n", 2014-05-09 21:23 can you check if we set -EIO in the driver somehwhere 2014-05-09 21:25 yes, in jz4740_mmc_transfer_check_state() : http://lxr.free-electrons.com/source/drivers/mmc/host/jz4740_mmc.c?v=3.12#L220 2014-05-09 21:27 yea, but does it actually run that code in your case? 2014-05-09 21:28 and then the next question is why is the error condition valid 2014-05-09 21:29 wolfspraul has quit [Quit: leaving] 2014-05-09 21:29 anyway, I'll be away for a while 2014-05-09 21:31 larsc: okay, will check if we set EIO in the mmc driver 2014-05-09 21:31 thanks for helping :-) 2014-05-09 21:41 wej has joined #qi-hardware 2014-05-09 21:55 kanzure has joined #qi-hardware 2014-05-09 22:56 sb0 has quit [Quit: Leaving]