On Wed, 27 Jan 2010, Spencer Oliver wrote:

> > When do_semihosting() returns with an error, the caller should return right
> > away with 1 as the original code did and not 0 like the patch does.
> > 
> 
> I am confused as the code in git master is:
> if ((*retval = do_semihosting(target, &arm->semi_hosting_info)) != ERROR_OK)
>       return 0;
> 
> this codepath has not changed.

Where is that?

My repository is currently at:

        33fc60b SVF: all content between parentheses is one parameter

and the code that your patch changed is still:

        *retval = do_semihosting(target);
        return 1;

at the very end of arm_semihosting().


Nicolas
> > Also I don't like the fact that the introduced arm_semi_hosting structure
> > (which could have been done in a patch of its own btw) is carrying fields
> > that are valid only for one particular instance of a semihosting call and
> > therefore should have been kept local to the implementation rather than
> > growing the arm structure uselessly.  Those are "result" and "core_cache".
> > I think that getting r0 and r1 should be abstracted out of do_semihosting()
> > and passed directly by both callers instead, etc.
> > 
> 
> it is wip, and so can be cleaned up quite a bit.

Sure, hence my comments.  But David apparently has a better solution in 
mind.

> > Finally the fix for FLEN could be split in a patch of its own too as this is
> > clearly an orthogonal issue.
> > 
> 
> this can be done no problem.

Thanks.


Nicolas
_______________________________________________
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to