On Wed, Dec 26, 2018 at 9:20 AM <
joey....@gmail.com> wrote:
>
> The arg1 is a ptr to a structure while has an pointer to another struct which I need to pass to arg2.
>
> Do you have any suggestion on the code implementation?
> For example can I declare in description file that arg1 as global struct, which I then can pass to another syscall (instead of random input to the 2nd sycall)?
You need to pass a pointer or the struct (pointee)? It's hard to
understand what exactly you want to achieve, and details matter. What
device/ioctl is this? Please a pull request what what you have now,
this will make it easier to understand what we are talking about.
> 在 2018年12月26日星期三 UTC+8下午3:34:20,Dmitry Vyukov写道:
>>
>> On Wed, Dec 26, 2018 at 4:21 AM <
joey....@gmail.com> wrote:
>> >
>> > Hi,
>> > Assume I have the syscalls execution like below:
>> >
>> > r0=syz_open_dev("/dev/xx", ...)
>> > ioctl$A(r0, cmd1, arg1)
>> > ioctl$B(r0, cmd2, arg2)
>> >
>> > Where I want arg1 and arg2 are exactly the same pointer, is it possible?
>>
>> Hi Joel,
>>
>> No, unfortunately this is not supported. Since this is needed only for
>> io_submit/io_cancel of known syscalls, this was never implemented.
>>
>> > And another question is:
>> > if arg2 is sub member of arg1, how can I pass it to ioctl$B?
>>
>> Please clarify what you mean by sub member. Like is it a
>> pointer/value? What type of value? Created by user/kernel?
>
> --
> You received this message because you are subscribed to the Google Groups "syzkaller" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
syzkaller+...@googlegroups.com.
> For more options, visit
https://groups.google.com/d/optout.