**** BEGIN LOGGING AT Mon Feb 14 02:59:57 2011 Feb 14 07:19:39 Can anyone help me get ofono compiling (specifically the MeeGo version of ofono)? I want to modify test-sms.c with some changes, recompile it and then run the result (either on an x86 host PC or my N900 device will do) Feb 14 07:20:03 More specifically I have a dump of a Cell Broadcast SMS message and I want to run that through the ofono decode code to see just what its contents are Feb 14 07:20:22 but I dont know what environment I actually need to compile ofono Feb 14 07:23:12 What if you install MeeGo SDK, and inside MeeGo runtime you compile it? Feb 14 07:23:59 it compiles on normal linux as well Feb 14 07:25:20 so if I put the source on my Gentoo box and run the configure scripts etc, it will build an x86 binary for all the test programs? Feb 14 07:25:58 Yes, but it will be not compatible with native MeeGo. Feb 14 07:26:01 if you have the correct headers/depends and use the correct configure arguments, I suppose so Feb 14 07:26:48 thanks Feb 14 09:54:25 courmisch: ping Feb 14 09:54:43 courmisch: please, phonet questions i have no idea whom to ask about. Feb 14 09:56:44 ? Feb 14 09:58:40 courmisch: hello Feb 14 09:58:56 courmisch: the task at hand: forwarding data back and forth between ``phonet0'' and ``upnlink0'' on n900. Feb 14 09:59:04 courmisch: a naive attempt at simply following the kernel documentation and creating PF_PHONET socket failed: i can't receive anything from uplink. Feb 14 09:59:15 of course not Feb 14 09:59:16 courmisch: a _ton_ of netlink magic in gisi/ is confusing even more. Feb 14 09:59:22 PF_PHONET sockets are to receive data locally Feb 14 09:59:33 you don't create PF_INET sockets if you want to route IP packets, do you? Feb 14 09:59:50 I would very much appreciate it if you explained the easiest way to do this (and difference between maemo and upstream kernels). Feb 14 10:01:00 bah you need to configure the local Phonet address (probably 0x6C) and routes to the (0x10 to uplink0, 0x00 to phonet0) Feb 14 10:01:02 courmisch: i assumed that for p2p link i am just to create a socket and then receive data over it. And send over another, corresponding to the other p2p link. phonet is rather confusing to me, there's too little docs or i'm just not smart enough to understand those. Feb 14 10:01:04 with Netlink Feb 14 10:01:41 courmisch: is that documented anyhow anywhere? At least the concept, i can get details from the sources. Feb 14 10:02:02 Phonet uses the standard rtnetlink, as documented in rtnetlink man pages Feb 14 10:02:16 courmisch: do you mean to actually do forwarding i can "simply" do several netlink calls to configure routing and there's no need for any kind of forwarding daemon? Feb 14 10:02:50 Well, netlink is just a communication channel between the kernel and userspace, and it's not obvious what to send over it in this case. Feb 14 10:03:49 yes in upstream kernel that's how it works Feb 14 10:04:06 But not in maemo 2.6.28 fork? Feb 14 10:04:15 that code did not exist then no Feb 14 10:04:40 Is there probably a userspace tool ready that can be used to do the config then? Feb 14 10:05:28 BTW, some member of ofono project wrote plenty of that netlink code for gisi, but i have no idea where he got the ideas and knowledge. Do i miss some important documentation? Or is everything in the committed upstream kernel sources? Feb 14 10:05:55 personally, I don't think oFono should do any netlink stuff other than to watch the status Feb 14 10:06:01 but someone decided otherwise Feb 14 10:06:43 Sounds rather cryptic :-o Feb 14 10:07:49 I'm sorry for asking questions not in the most clear way, i'm not a native speaker. I still hope you can understand me enough, or i can clarify more if that's too hard. Feb 14 10:14:32 courmisch: (configure local phonet address) to what interface? Anything else to enable the routing? The whole concept is unclear to me. I understand how to configure routing for UDP between different interfaces, should phonet be similar? Feb 14 10:17:03 (and with ip routing table entries are actually added automatically by default, based on the addresses assigned to the interfaces) Feb 14 10:36:00 if you're targetting N900 with the 2.6.28 kernel you're kinda screwed Feb 14 10:36:08 there was no routing support in that old version Feb 14 10:36:38 IIRC, routing was hacked using PF_PACKET sockets and some magic BPF filters Feb 14 10:38:00 courmisch: ok, what if i'm targetting upstream kernels for n900? Feb 14 10:42:17 courmisch: you know i'm fairly versed in using linux for routing/networking ip-based networks, i know how to use "ip", i understand netmasks etc. Do you really mean i should be able to understand how to route phonet without any extra docs, just rtnetlink and phonet.txt? Is there any design rationale explanation or anything? I can't really understand how one could have written all that code in ofono without additional clues. Feb 14 10:43:24 I don't think iproute supports the Phonet address family Feb 14 10:43:28 but rtnetlink as such does Feb 14 10:44:03 you just need to configure address 0x6C and route 0x00 on phonet0, and route 0x10 on upnlink0 Feb 14 10:44:09 and make sure both interface are UP Feb 14 10:45:53 courmisch: i'm used to the concept address(es) belong to interfaces. So when i hear "configure address 0x6C" (SOS) i start thinking "to what interface". Feb 14 10:48:52 hmm, a 5liner comment about *basic* concept sure would help Feb 14 10:49:53 I think I already answered that Feb 14 10:50:54 ok, so let me do that for you Feb 14 10:52:54 there's a daemon in userland that opens to network connections, one to ISI and one to USB, the one has 0x00 as address, the other 0x6c. Then data is just forwarded UDP, using addr 0x10 as magic sauce on top Feb 14 10:53:36 I guess I failed :-D Feb 14 10:59:28 courmisch: so, do you mean you've answered all of my questions you felt like answering? Ok, thanks. Will get back to you if i still have problems. Feb 14 11:00:29 * DocScrutinizer frowns Feb 14 11:02:58 DocScrutinizer: in N900, softupd does the forwarding, but it does a lot more than forwarding. I don't even know what it exactly does Feb 14 11:03:47 courmisch: we know that but softupd's source is misteriously missing, so we can't use it with upstream distros. Feb 14 11:03:57 courmisch: thanks :-) I figured as much as softupd being the relevant bit Feb 14 11:04:48 upstream distros should not be using 2.6.28 anyway Feb 14 11:04:53 They do not. Feb 14 11:05:07 routing is built-in kernel since 2.6.35 or so Feb 14 11:05:20 they need a replacement for softupd though Feb 14 11:05:43 But it seems only you know how exactly to use it... Feb 14 11:06:58 Design rationale document for Phonet is nowhere to be found, hence it's hard to see the bigger picture. Feb 14 11:07:41 I'd not be asking about it here if you pointed me to some document. Feb 14 11:08:59 or we'd probably be happy -regarding this topic- with a 'smaller picture' design rationale comment on how things are supposed to work on 35+ kernels, for forwarding/routing Feb 14 11:09:01 Also i can't understand what you told me about ofono's phonet code. Feb 14 11:09:46 denkenz: any news on my patches for sms cancelling? Feb 14 11:10:26 I just told you! Add address 0x6C and route 0x00 on phonet0, add route 0x10 on upnlink0. Bring up both. All with standard rtnetlink Feb 14 11:10:37 courmisch: for ip interfaces routing entries are added automatically. What makes phonet different? Feb 14 11:10:50 we must have different IP stacks Feb 14 11:11:35 (and I'm using the Linux one) Feb 14 11:12:02 PaulFertser: it is just like p2p links on ip, you have local address and (route to) remote address Feb 14 11:12:31 courmisch: i do "ip a a 192.168.2.1/24 dev eth0" and then "ip l s eth0 up" and "ip r" shows the routing entry for eth1. Feb 14 11:13:03 pessi: yes, and the route table entry is created automatically, isn't it? Feb 14 11:13:25 PaulFertser: so hmm, you claim the IP stack guesses the gateway? you're kidding me? Feb 14 11:14:04 PaulFertser: eth0 is not a p2p link Feb 14 11:14:20 with IP, either you have a netmask, and you need to add a default route (with a gateway). Or you have a ptp link, and you need to add a default route (w/o gateway) Feb 14 11:14:23 courmisch: of course gateway is additional routing entry, to be added manually. Feb 14 11:14:29 phonet is the ptp case Feb 14 11:14:54 point is, either way, with IP you need to add a route Feb 14 11:16:14 Ok, imagine i have ppp0 with local address N and remote address M. Do i manually have to create routing to send packets to M? As far as i remember, no. Feb 14 11:16:33 you do Feb 14 11:16:41 well, maybe pppd does the setup Feb 14 11:16:46 but basically, someone has to Feb 14 11:16:52 :-) Feb 14 11:17:27 Ok Feb 14 11:17:59 as for softupd, don't hold your breath. Nokia won't OSS production stuff in my understanding Feb 14 11:18:31 we're painfully aware of this Feb 14 11:26:55 courmisch: i just did ``ip a a 192.168.105.1/32 peer 192.168.105.5 dev eth0'' which according to iproute2 documentation should create a p2p link, and i got ``192.168.105.5 dev eth0 proto kernel scope link src 192.168.105.1'' in ``ip r'' output, clearly this entry was added automatically by the kernel, no? Feb 14 11:36:40 PaulFertser: no, ip set it through an rtnl command. Feb 14 11:37:32 sameo: ip assigned address to the interface via rtnl, yes. But what about the routing entry, do you mean "ip" modifies routing itself even when not asked (ip address ... commands)? Feb 14 11:38:02 you explicitely set a peer, that needs routing table modifications. Feb 14 11:38:22 so you did ask for it, and ip did it for you. Feb 14 11:40:05 sameo: as i'm observing the "ip" source, it tells me it just prepares a RTM_NEWADDR rtnl message. With IFA_ADDRESS additional attribute added to the netlink message. Feb 14 11:41:18 sameo: do_ipaddr() function in ipaddress.c Feb 14 11:46:13 right, but here the kernel didn't guess anything. it set the gateway because you told you want a p2p interface and you specified a peer. Feb 14 11:54:40 sameo: i'm not talking about the gateway at all. See, i traced the code, it happens like that: ip userspace utility issues RTM_NEWADDR message. Then __inet_insert_ifa() schedules FIB update with NETDEV_UP, which is handled by fib_inetaddr_event() which calls fib_add_ifaddr() which prepares a new RTM_NEWROUTE message. Feb 14 11:55:15 sameo: so why can't phonet do the same for me automatically when i assign "remote peer address" to an interface? Feb 14 11:57:21 In fact phonet doesn't even have any handler at all for RTM_NEWADDR! Feb 14 11:57:31 HEhe, sorry. Feb 14 11:58:56 Of course it does but it doesn't think it's necessary to automatically setup routing on address assignment. Why? Feb 14 11:59:07 What's the rationale on that? Feb 14 12:14:05 courmisch: now i see that phonet can only set IFA_LOCAL address but not the peer's address (IFA_ADDRESS) despite being peer-to-peer by design. And it doesn't add the routing entry automatically because it lacks necessary handling (which ipv4 doesn't). Why is that? Feb 14 12:14:33 (i'm looking at 2.6.37 sources now) Feb 14 14:59:25 padovan: ping Feb 14 15:02:26 Gzajac: pong Feb 14 15:04:03 I have used your implementation of DUN dial_cb and I would like to test it. Do you have a test scenario for me? Feb 14 15:04:41 I mean for testing ppp server of emulator. Feb 14 15:07:09 Because I don't know how to test it. Feb 14 15:12:45 Gzajac: gatchat/gsmdial Feb 14 15:16:03 denkenz: thx. I will try to use it. Feb 14 15:21:24 denkenz: could you please have a look at "[PATCH 1/1] gatserver: Add ATS5 command feature" as this is a bugfix ? thanks Feb 14 16:38:30 PaulFertser: we don't do peer-to-peer parameter. Only RTM_NEWROUTE Feb 14 16:39:23 courmisch: i deduced that from the code already. But i can't see the reasoning behind such a choice. Feb 14 16:41:43 I don't think there is a reasoning Feb 14 16:42:02 we need to support RTM_NEWROUTE anyhow, as upnlink0 has no address Feb 14 16:42:34 It would feel logical to get two addresses from RTM_NEWADDR and automatically add a corresponding route. And i think i proved it works that way for ipv4 with actual references to the code. Feb 14 16:43:13 we still need NEWROUTE for address-less devices and for default route Feb 14 16:43:33 you're free to send a patch for IFA_ADDRESS to netdev Feb 14 16:44:42 in matd, we made ATS5, ATS4 and ATS3 only accept the default values. IIRC, we passed DUN certification with that. Just so you know Feb 14 16:47:25 ...or better yet patch the SSI McSAAB driver to implement automatic peer address like the USB CDC driver does Feb 14 16:47:27 DUN is a strange and sick hack, bluetooth has proper support for networking instead. And if one wishes to use "raw" modem so much, he should probably get just raw pppd stream connected with RFCOMM instead... Feb 14 16:47:38 since SSI is not usptream yet that i know, I can't do that myself Feb 14 16:48:11 PaulFertser: if you mean PAN, it's not adequate for GPRS Feb 14 16:48:26 GPRS is a point to point link, you can't cleanly emulate it with Ethernet Feb 14 16:49:04 courmisch: n900 is powerful enough for doing ipv4 NAT afaict. Feb 14 16:49:08 AT commands stink and PPP is not most efficient, but at least it fits the connectivity model Feb 14 16:49:17 I consider NAT'ing inferior to direct GPRS Feb 14 16:49:45 if only because it avoids IP address conflicts on both side of the NAT, and because my 3G operator gives me public IP addresses (that my PC can enjoy) Feb 14 16:50:21 not to mention that GPRS connection time out is longer than DHCP, so you have a problem if the connection is not already up when the PC connects USB / BT Feb 14 16:56:30 courmisch: ("as upnlink0 has no address") this is an example why i feel that phonet really lacks documentation, i see no way how i can deduce that from phonet.txt. Also i guess there's already a tool exist to list and manipulate addresses and routing entries (or else how that functionality would be debugged), but where is it and why isn't it mentioned in phonet.txt? Feb 14 16:57:10 it's not published yet therefore not mentioned Feb 14 16:57:44 and hey, I had no documentation either. Nowadays, you can get the WG modem spec at least Feb 14 16:58:43 much better than what I worked with - just huge header files with plenty of magic number defined Feb 14 17:00:47 I feel rather frustrated because i clearly see that there're some tools and some documentation available and everything happens besides the scenes, e.g. google doesn't show much hints about phonet discussions on netdev list. Ok, consider me a loosy developer but somehow it happened my friends spend plenty of time trying to understand how to make forwarding work. Now that you've told me about the routing and addressless interface i start to u Feb 14 17:03:09 to u? Feb 14 17:03:21 well, the PC stuff works mostly out of the box Feb 14 17:03:31 all you need is "ifconfig usbpn0 up" Feb 14 17:04:16 as for N900 you're supposed to use the Nokia kernel and userspace. There ain't even an SSI driver in upstream yet. Feb 14 17:07:12 courmisch: who supposes a strange fork based on 2.6.28 and a bunch of proprietary tools in the userspace can be a good choice?.. ofono project promised to come up with n900 support at about a year ago. There still isn't anything usable alas. You might be surprised but it's quite possible that it'll be FSO that'll first run on n900 actually supporting all the needed phone features... Feb 14 17:07:48 Gzajac: enable the modem and use gsmdial -b to dial Feb 14 17:08:10 PaulFertser: promised not be me Feb 14 17:08:13 PaulFertser: I have been pretty patient here when it comes to discuss FSO features and wishes, but keep in mind this is an oFono IRC channel. Feb 14 17:08:24 courmisch: of course, i do not blame anyone even. Feb 14 17:08:29 and I don't recall anyone asking details on my nokia.com mail address Feb 14 17:08:37 holtmann: i do, thank you. Feb 14 17:08:53 PaulFertser: So you might wanna take this to a different channel. Feb 14 17:09:55 holtmann: i just tried to explain why more openness around Phonet would be beneficial to the community as a whole. Feb 14 17:10:18 you should explain why it would be beneficial to Nokia Feb 14 17:11:37 and I don't see much Nokia's benefit in FSO. Especially when N900 is not anymore on sale and it won't make any extra sale. Feb 14 17:11:39 courmisch: (asking details on nokia.com mail address) i hope i can consider as a sign that you can provide some help to FSO when asked via it, thanks (no sarcasm or anything). Feb 14 17:12:07 well now that's Nokia is almost killing MeeGo, you're a bit late Feb 14 17:14:58 courmisch: (beneficial to Nokia) Nokia is going its own strange ways, i can't explain much about it; but what i can see is that there's almost no option for users who want decent userspace on a decent mobile phone device, so helping any project that tries to remedy that is beneficial to those users. Feb 14 17:17:18 phonet routing does not strike me as the most immediate need for FSO Feb 14 17:17:27 I mean, who cares if you can use phonet from the PC Feb 14 17:18:58 courmisch: those who actively develop interaction with ISI modem want to be able to debug the code natively on their PCs, just that. And with maemo running on device they can't test other parts of the system. Forwarding will be useful, i hope now your help will allow me to do that, thank you. Feb 14 17:21:08 PaulFertser: This is rather weird request and pointless. Feb 14 17:21:51 Development on a PC is nice, but with oFono it is as simple to compile or cross-compile on a PC and send update the package. Feb 14 17:22:19 That FSO has a hugh dependency list is your problem actually. With oFono this is all nice and simple. Feb 14 17:22:30 I can try to clean up phonet-utils and push it to gitorious.org as soon as akiniemi creates a repo for it Feb 14 17:22:38 holtmann: FSO folks are rather weird too :) Feb 14 17:22:45 but with the current situation at Nokia, no promises whatsoever Feb 14 17:23:30 courmisch: thank you Feb 14 17:23:49 well, real problem is oFono cannot work on PC very well as it does not cope with some other entity (the application engine) touching the modem. Feb 14 17:24:49 in Nokia CSD, this kinda worked because Phonet provides notifications for that sort of stuff. But AT commands don't and so oFono is screwed Feb 14 17:26:33 holtmann: i think currently FSO depends only on dbus and glib (also nl where it really needs it), vala compiles everything to native code without additional deps. Feb 14 17:36:04 *shrug* forwarding is not pointless nor weird request at all. cross-compiling and sending an updated package to the phone plus debugging right on the phone is way more involved. not much sense in denying that fact Feb 14 17:37:55 mickey|bbl: All this stuff only gets you so far. At some point you just have to get things working on the phone. And stop bothering with forwarding. Feb 14 17:38:11 correct Feb 14 17:38:25 this point is not here yet. Feb 14 17:38:30 Or just realize that you really wanna use oFono actually. Feb 14 17:38:35 we don't, thanks Feb 14 17:41:15 Then good luck, but this is still an oFono IRC channel and not a FSO one. Feb 14 17:41:27 true Feb 14 17:41:31 i've not mentioning FSO at all Feb 14 17:41:32 never Feb 14 17:41:38 i've been asking about n900 forwarding Feb 14 17:41:41 that's all Feb 14 17:41:55 As I said, I have been pretty patient here with all of this, but don't overstretch your luck. Feb 14 17:42:06 oFono works on the PC side over ISI and also on the N900 via ISI. Feb 14 17:43:51 yes, as long as maemo's proprietary daemon forwards packages. Feb 14 17:51:35 that's irrelevant. It works as long as the device supports Phonet over USB Feb 14 17:52:19 it could be Maemo softupd, S60 stuff, direct connection to an S40 phone, or open-source fork of N900 Feb 14 17:55:15 oh yes, i can see how irrelevant this is. *sigh* Feb 14 20:02:52 padovan: Can you take a look at the single SDP record patch? Feb 14 20:03:06 Its looking good to me besides a few style issues Feb 14 20:05:12 denkenz: ok, I'll have a look. Feb 14 21:47:28 i think configure needs a bluez version check, some structures don't match in ancient bluez-libs Feb 14 21:50:56 Which ones? Feb 14 21:53:26 struct sockaddr_l2 has no .l2_cid in.. 3.36 (i know..) Feb 14 21:54:07 Right. And we added the L2CAP channel stuff to btio.c Feb 14 21:54:23 So yes, we need a version for bluez. Feel free to send a patch for that. Feb 14 22:09:48 also it seems src/genbuiltin didn't get re-run when i reconfigured (not sure what the builtin.h dependency in the Makefile should be on) Feb 14 22:11:26 maybe on config.h Feb 14 22:36:17 hello Feb 14 22:37:41 I'm running ofono 0.41 on an n900 and when I try to use Data through a connection context the modem "reboots" **** ENDING LOGGING AT Tue Feb 15 02:59:56 2011