DMA on stack?

Marcelo Tosatti marcelo at kvack.org
Wed Nov 21 11:22:35 EST 2007


On Wed, Nov 21, 2007 at 09:27:44AM +0100, Oliver Neukum wrote:
> Am Dienstag 20 November 2007 schrieb Marcelo Tosatti:
> > Not an issue since that data is copied to a SLAB allocated region before
> > submission to HW.
> 
> Good. Out of interest, where in this deep call chain is it allocated?

libertas_prepare_and_send_command->wlan_cmd_mesh_access:

static int wlan_cmd_mesh_access(wlan_private * priv,
                                struct cmd_ds_command *cmd,
                                u16 cmd_action, void *pdata_buf)
{
        struct cmd_ds_mesh_access *mesh_access = &cmd->params.mesh;
        lbs_deb_enter_args(LBS_DEB_CMD, "action %d", cmd_action);

        cmd->command = cpu_to_le16(CMD_MESH_ACCESS);
        cmd->size = cpu_to_le16(sizeof(struct cmd_ds_mesh_access) + S_DS_GEN);
        cmd->result = 0;

        if (pdata_buf)
                memcpy(mesh_access, pdata_buf, sizeof(*mesh_access));
        else
                memset(mesh_access, 0, sizeof(*mesh_access));

        mesh_access->action = cpu_to_le16(cmd_action);

        lbs_deb_leave(LBS_DEB_CMD);
        return 0;
}




More information about the libertas-dev mailing list