[PATCH] serial-port: turn open_count assertion in mm_serial_port_close into simple return

Ben Chan benchan at chromium.org
Sun Jan 12 18:48:39 PST 2014


> One option would be to have all the MMQueueData items be completed in an
> idle, so that when they are really completed the port was already marked
> as forced_close. I know it's probably too much just to handle this case,
> but I also think it's important to warn about the incorrect open/close
> counts; and the idle completion is actually a good idea as we avoid
> chaining up normal close()s within the forced_close() call.
>
> I'd suggest to wait until we release 1.2, because after that I'd like to
> merge the 'aleksander/ports-refactor' branch, and in that branch the
> change needed to have the MMQueueData item (named CommandContext in the
> branch) completed in idle is just a rename of
> g_simple_async_result_complete() to
> g_simple_async_result_complete_in_idle().
>

complete_in_idle would work but that requires all contexts to be aware
of the semantics. Is the CommandContext going to replace all contexts
(i.e. one rename is enough)?


More information about the ModemManager-devel mailing list