DocScrutinizer05 changed the topic of #qi-hardware to: Copyleft hardware - http://qi-hardware.com | hardware hackers join here to discuss Ben NanoNote, atben / atusb 802.15.4 wireless, and other community driven hw projects | public logging at http://en.qi-hardware.com/irclogs and http://irclog.whitequark.org/qi-hardware
xiangfu has joined #qi-hardware
<DocScrutinizer05> http://neo900.org/ minor improvements on page design
<pcercuei> looks... interesting
<pcercuei> it's a GTA04, inside a N900 case?
dos1 has quit [Ping timeout: 263 seconds]
<wpwrak> whee ! now it has a keyboard :)
<wpwrak> the feature list looks impressive :)
<wpwrak> maybe also mention display and battery ?
<wpwrak> ... since it's already more a feature list than a mere comparison chart :)
<pcercuei> what would be the price of something like that?
porchao has joined #qi-hardware
<qi-bot> [commit] Werner Almesberger: modules/tswa.fpd: add hole to through-hole pads (master) http://qi-hw.com/p/kicad-libs/a808cc1
<qi-bot> [commit] Werner Almesberger: modules/stdpass.fpd: add 1008 (for Samsung CIG22L4R7MNE inductor) (master) http://qi-hw.com/p/kicad-libs/2cf146c
<qi-bot> [commit] Werner Almesberger: components/aat1217.lib: Skyworks AAT1217 step-up converter (master) http://qi-hw.com/p/kicad-libs/dc5ce7a
<qi-bot> [commit] Werner Almesberger: modules/sot.fpd: add 236 (23-6) footprint (master) http://qi-hw.com/p/kicad-libs/784f0e6
pcercuei has quit [Quit: dodo]
xiangfu has quit [Remote host closed the connection]
heberth has quit [Quit: leaving]
Jay7 has quit [Ping timeout: 246 seconds]
Jay7 has joined #qi-hardware
Luke-Jr has quit [Excess Flood]
Luke-Jr has joined #qi-hardware
xiangfu has joined #qi-hardware
Luke-Jr has quit [Ping timeout: 260 seconds]
Luke-Jr has joined #qi-hardware
Luke-Jr has quit [Read error: Connection reset by peer]
Luke-Jr has joined #qi-hardware
Luke-Jr has quit [Read error: Connection reset by peer]
Luke-Jr has joined #qi-hardware
Luke-Jr has quit [Excess Flood]
Luke-Jr has joined #qi-hardware
jekhor has joined #qi-hardware
xiangfu has quit [Ping timeout: 240 seconds]
wolfspraul has joined #qi-hardware
<wpwrak> roh: ever tried resin casting ? e.g., polyester or acrylic ? it seems that this is almost as good as injection molding - with chemistry replacing the fancy machines
FDCX_ has joined #qi-hardware
xiangfu has joined #qi-hardware
pcercuei has joined #qi-hardware
lekernel has joined #qi-hardware
<qi-bot> [commit] Werner Almesberger: components/er-oled-fpc30.lib: change pin 30 from NC to GND (master) http://qi-hw.com/p/kicad-libs/c5278c5
<qi-bot> [commit] Werner Almesberger: add C&K JS102011SAQN SPDT SMT switch (symbol and footprint) (master) http://qi-hw.com/p/kicad-libs/18ed84d
<qi-bot> [commit] Werner Almesberger: components/kl25-48.lib: add pin 49 for the center pad (master) http://qi-hw.com/p/kicad-libs/b32bd32
FDCX_ has quit [Ping timeout: 264 seconds]
dandon_ has joined #qi-hardware
dandon has quit [Ping timeout: 256 seconds]
dandon_ is now known as dandon
<whitequark> hm
<larsc> hm, anybody has a /dev/video device on their system and wants to test something for me?
<whitequark> larsc: I've a webcam
<larsc> whitequark: try http://pastebin.com/xKxgLKKu (may crash your machine though)
<whitequark> ret: -1 14
<whitequark> nothing else
<larsc> yea, that's kind of what I expected
<roh> wpwrak: nope. forms are still the major work
<roh> and i dont like chemicals
<larsc> whitequark: but with a better magic number I think you could get it to expose any physical mempry
<whitequark> larsc: hm strange
<lekernel> when will people stop using C for everything? :)
<lekernel> and even before that, userspace drivers would be a GREAT idea.
<lekernel> Linux isn't even consistent - e.g. for USB, you can either write a kernel module or use libusb. same with FUSE. two APIs where there should be only one.
<whitequark> lekernel: uhhh, FUSE is also incredibly slow
<whitequark> also I haven't really seen well-written FUSE drivers, except perhaps ntfs-3g, though that may have another reason
<whitequark> e.g. MTP is unusable.
<lekernel> yeah well, the fundamental idea is that parsing/generating filesystem structures needs not be done in kernel space.
<whitequark> I call bullshit... there's been n+1 attempt at microkernels and they never worked
<whitequark> what you actually need is a safe language which doesn't allow errors in parsing/generating filesystem structures to lead to memory corruption
<lekernel> and why didn't those microkernels work, exactly?
<whitequark> too slow
<whitequark> (of course, most of them died because of other, social reasons. but the technical reason is "too slow".)
<lekernel> I'd say minix, for example, pretty much works.
* whitequark sighs
<whitequark> let me phrase it another way.
<whitequark> if you have a kernel written in a memory-safe language, is there any reason to keep kernel components in separate address spaces?
<lekernel> that sounds harder to do than a microkernel
<whitequark> you *can* use messaging if it's more convenient; you *can* restart tasks if they fail; you just don't have to, if that's too slow
<whitequark> eh
<lekernel> and what about untrusted proprietary kernel modules?
<whitequark> lekernel: those can very well use FUSE and be slow as hell, imo.
<whitequark> they're heavily penalized (not in perf) right now anyway
<whitequark> lekernel: (harder to do) well, let's now compare my scheme to yours--which, as I understand it, is components written in unsafe language, but kept in separate AS's
<whitequark> so what do I do if I pwn a filesystem server? I rewrite kernel image.
<whitequark> DONE>
<larsc> but /dev/video devices can usually be accessed by a normal user, can't it?
<whitequark> larsc: true
<whitequark> what you found looks like a bug, no?
<larsc> a zero day
<larsc> ;)
<whitequark> what does it do on your machine?
<whitequark> how did you find it?
<larsc> hadn't had the chance to test yet on my machine
<larsc> I'm writing code similar to the v4l buffer code and noticed that they didn't check this case
<larsc> that check should basically be if (count > buf->size || buf->pos + count > buf->size)
<larsc> or count > buf->size - buf->pos
<wpwrak> hmm, fedex seem to have slowed down their southern cone operations. shipment left only last night. so that's the full 2 day weekend penalty instead of just one.
<ysionneau> sending messages between "system" services is much slower than function call I imagine
<ysionneau> and then you have context switch as well
<ysionneau> but the idea of just restarting a daemon instead of kernel panicing is indeed nice :)
<wpwrak> yes, especially because we all know that the best-written and best-tested code in drivers is usually the exit/cleanup code ;-)
<roh> wpwrak: well.. usually thats even correct
<roh> or have you seen sane error handling code in daemons?
<lekernel> ysionneau, including with hardware support for fast context switch?
<ysionneau> for the lucky enough arch to have fast context switch maybe the penalty is small
<wpwrak> roh: i mean comparing "regular use" driver code vs. "cleanup" driver code :)
<lekernel> I think it's possible to have an instruction as fast as a jump that can context-switch between a dozen cached processes
<wpwrak> roh: but yes, whenever something gets special error-handling procedures, the chance of getting them wrong is pretty high
<ysionneau> with some kind of process ID and register shadowing?
<lekernel> yes
<ysionneau> imo arm does that (or some other arch I don't remember) for 2 processus
<ysionneau> maybe cortex-R something
<lekernel> make that 16 and I'm sure microkernels will have no perf penalty whatsoever
<roh> wpwrak: atleast in drivers i KNOW people thought about cleanup. in daemons people dont give a shit and just segfault all the time
<roh> lekernel: 16? gnihihi... on a recent desktop you'd need a few hundred for hw drivers alone
<ysionneau> thats for not trashing TLB
<lekernel> not active within microseconds of each other
<roh> you got 16 real cpus on a computer.. so i guess the numbers need to be higher
<wpwrak> roh: yeah, daemons are built with other assumptions. and/or less regard for considering the assumptions :)
<lekernel> that's why I said *cached* processes
<wpwrak> 16 seems pretty deep already. if you go that deep for frequently used things, you may have a serious complexity problem :)
<roh> wpwrak: i guess that was implicated when we started building computers with dozends of cores, didnt weß
<roh> anyhow.. bbl.. gotta use the non-rain-period
<lekernel> message passing between CPU cores is slow
<lekernel> context-switching the current core with that special instruction is fast
jow_laptop has quit [Quit: leaving]
jow_laptop has joined #qi-hardware
<larsc> if you have managed code you don't need memory protection anyway and everything runs in the same context ;)
<ysionneau> =)
jekhor has quit [Ping timeout: 260 seconds]
<wpwrak> "if you have nothing to hide, there's no reason to be afraid" ;-)
<wpwrak> "if you don't have any enemies, there's no need to worry about exploits"
<wpwrak> damn. this is so easy. why do i torture myself with code and electronics when i could have become a politician ?
<Freemor> wpwrak: I'm guessing because you have a soul
<wpwrak> someone once said: "in politics, honesty is everything. once you can fake it convincingly, you've made it."
wolfspraul has quit [Ping timeout: 276 seconds]
<whitequark> ha
wolfspraul has joined #qi-hardware
<roh> re
<roh> larsc: i think memory protection without using memory mapping is a nice idea
<roh> basically.. run everything as position independant code. same memoryspace, but with protection. nowadays you even got io-mmus in your hardware, so it should be faster than what we do now
<whitequark> the things you do to avoid using safe languages :p
<roh> whitequark: safe languages do not avoid people wanting to abuse interfaces or brainfarts like off-by-ones and similar think-o-s
<larsc> it's not about the language, it's about malicious applications
<roh> so.. doing stuff right isnt anything you get around anyhow.
<larsc> with managed applications you basically do the memory protection in sw
<whitequark> roh: yeah, off-by-ones and logic errors generally are the same, but they cannot lead to code execution in arbitrary places
<roh> larsc: thats pure theory. in reality thats all bogus. nobody really uses such stuff outside the lab
<roh> whitequark: oh yes, they can.
<whitequark> roh: how so?
<whitequark> note the "arbitrary", if you explicitly load a chunk of code and jump to it, sure. but it is generally easier to make sure all code paths to something like that are good
<whitequark> than to check every single array access everywhere
<roh> whitequark: also.. you got shitloads of badly programmed and even less understood hardware, capable of dma and similar memory access patterns... how do people get to the impression that somebody hostile with enough time would NOT be able to place arbitrary binaries at the right place in memory?
<whitequark> roh: perfect security is impossible (with real-world hw), but you can raise the barrier
<roh> so.. YES you need iommu hardware and correctly programmed drivers.
<roh> and proper hardware. and STILL you need to audit your code. and against none of those errors a programming language can help you.
<whitequark> that still doesn't protect you from bugs in cpus/iommu hw
<whitequark> eg recent xen issue
<roh> so.. forget that bullshit that buffer overflows are your only problem. its only one of many. and a language doesnt save you from yourself.
<whitequark> roh: again: I'm not saying it *solves* security, it merely reduces the amount of stuff you need to care about
<roh> whitequark: no. it makes coders more stupid.
<whitequark> roh: bullshit. writing same trivial checks over and over again doesn't make you clever.
<roh> check out java. it didnt make more people able to code. it made more able to code very badly. thats not helping.
FDCX_ has joined #qi-hardware
<roh> whitequark: nobody does that. every sane person uses macros for that.
* whitequark silently points at the bug larsc found
<roh> whitequark: dont always look at 'i am a bad beginner'-code like openssl ;)
<whitequark> so, v4l2 code is 'i am a bad beginner'. ok
<whitequark> I don't care how much idiots are going to think they can code now. it's not a technical problem, it cannot be solved (or "unsolved") by technical means
<whitequark> I care about people who know what they do, spending less time doing pointless shit
<roh> exactly. so its not helping blaming bad tech, when its bad design by people. thats all i am saying.
<whitequark> well, languages which make you write hazardous boilerplate instead of actually important code do have bad design after all
<whitequark> (and java is just as guilty of that)
rz2k has joined #qi-hardware
lindi-_ has joined #qi-hardware
bartbes has joined #qi-hardware
bartbes_ has quit [Ping timeout: 240 seconds]
lindi- has quit [Ping timeout: 240 seconds]
wej has joined #qi-hardware
lekernel has quit [Ping timeout: 264 seconds]
xiangfu has quit [Quit: leaving]
dos1 has joined #qi-hardware
lekernel has joined #qi-hardware
dos11 has joined #qi-hardware
dos1 has quit [Read error: Connection reset by peer]
<whitequark> I bet someone here understands USB better than me
<whitequark> what's the rationale for having tokens DATA0,1,2 instead of just DATA ?
<whitequark> too much spare identifiers? :D
<DocScrutinizer05> wpwrak: I don't know why you say this table is more of a feature list than a comparison
wej has quit [Ping timeout: 245 seconds]
<wpwrak> DocScrutinizer05: i would read it as a feature list, because a) it mentions most of the main features b) i'd be more interested in learning about the features of the new product than those of some obsolete devices. of course, if you're coming from the N900, that may be different :)
<DocScrutinizer05> that table lists the differences, just that
<wpwrak> DocScrutinizer05: in terms of marketing, i think a good point to emphasize would be the fusion of three successful projects: 1) the gta04 OPEN hardware, 2) the nice Nokia case, and 3) the friendly and proven GUI.
<DocScrutinizer05> >>Neo900 will preserve all the features of N900. With upgrades!<<
<DocScrutinizer05> yep, exactly
<wpwrak> yes, but there are so many differences that you may just add the remaining features as well, even if they're the same :)
<DocScrutinizer05> a tad long
<wpwrak> well, key features. at least the screen :)
<roh> DocScrutinizer05: is there a list of parts for the mechanics and some explosion-drawing?
<roh> maybe even pricetags?
<DocScrutinizer05> well, there is schematics and service manual L1_2 and L3_4
<DocScrutinizer05> for n900
wej has joined #qi-hardware
viric has quit [Ping timeout: 240 seconds]
viric has joined #qi-hardware
Ornotermes has quit [Quit: leaving]
pcercuei has quit [Quit: leaving]
<larsc> hm, is their some magic build-in gcc macro that tells me whether X is a pointer or an array?
wolfspraul has quit [Quit: leaving]
<whitequark> larsc: __builtin_offsetof? __builtin_object_size?
<larsc> hm, I would I use them?
<whitequark> I imagine a pointer will usually be pointer-sized and array will be larger.
<whitequark> actually, nevermind
<larsc> usually
<larsc> but I found something that works
<larsc> #define IS_ARRAY(x) (!__builtin_types_compatible_p(typeof(&(x[0])), typeof(x)))
<whitequark> ha, clever usage of decay
<whitequark> but why do you want that?
<larsc> I want to check that the size of an buffer is large enough if we know the size at compile time
<larsc> hm, maybe thats __builtin_object_size?
<larsc> yea
<larsc> thought __builtin_object_size would just return 4 for an pointer
<larsc> but that's not the case
jekhor has joined #qi-hardware
rz2k has quit []
Jay7 has quit [Ping timeout: 264 seconds]
dos11 is now known as dos1
pcercuei has joined #qi-hardware
lekernel has quit [Quit: Leaving]
jekhor has quit [Ping timeout: 264 seconds]
<DocScrutinizer05> roh: what exactly are you interested in?
<DocScrutinizer05> pricetags for what in particular?
<DocScrutinizer05> I don't completely get it what you're asking for
Ornotermes has joined #qi-hardware
<DocScrutinizer05> the "Nokia" parts needed to build a complete device around a GTA04-NeoN board? We googled for them, part by part, from all over Europe and Asia. Some parts are hard to source, e.g. the domesheet. Others are abundance, like the case/shell plastic
<DocScrutinizer05> but basically yes, we found a source for every single one of those bits
<DocScrutinizer05> some - like the FPC with camera, proximity detector, ALS, and 3 color indicator LED and earpiece - are amazing cheap: ~7EUR
<DocScrutinizer05> other parts, like the main camera module, cost more than gold: ~50EUR
<roh> DocScrutinizer05: i see.. is there a wiki with that somewhere?
<roh> but good information
<DocScrutinizer05> nope, no wiki with all that knowledge/info yet
<roh> ;)
<DocScrutinizer05> it's also kinda volatile info, given the dynamics of fleabay etc
<DocScrutinizer05> and I'm afraid the situation might look different when we do same check again in 4 or 6 months from now
<DocScrutinizer05> availability of spareparts fro N900 at large depletes rapidly
<DocScrutinizer05> OTOH used, broken N900 seem to spread all over the fleabayshere
<DocScrutinizer05> sphere even